loiccoyle / zsh-github-copilot

🧠 GitHub Copilot for your command line
MIT License
56 stars 5 forks source link

Extension not found #4

Closed akaihola closed 4 months ago

akaihola commented 4 months ago

I installed GitHub CLI, the Copilot extension and zsh-github-copilot on NixOS using home-manager:

  programs.gh = {
    enable = true;
    extensions = [ pkgs.gh-copilot ];
  };

  programs.zsh = {
    enable = true;
    plugins = [
    {
        name = "zsh-github-copilot";
        file = "zsh-github.copilot.plugin.szh";
        src = pkgs.fetchFromGitHub {
          owner = "loiccoyle";
          repo = "zsh-github-copilot";
          rev = "main";
          sha256 = "sha256-zPw7/wzX05044rl9pObDpwANeviiKq2ohp3gt3Fqj8A=";
        };
      }
    ];
  }

zsh-github-copilot can't detect the Copilot extension since it's looking for gh-copilot in this output, but on my system there's no dash between gh and copilot:

$ gh extension list
NAME        REPO  VERSION
gh copilot

My GitHub CLI version is

$ gh version
gh version 2.52.0 (1980-01-01)
https://github.com/cli/cli/releases/tag/v2.52.0

Here's the error if I try to run the plugin manually:

$ . .zsh/plugins/zsh-github-copilot/zsh-github-copilot.plugin.zsh
zsh-github-copilot: gh copilot extension not found.%