Use the old Copilot CLI syntax in the new gh version #86354
-
Select Topic AreaQuestion BodyI still had the old I uninstalled the old one with Now, for the old one I still had aliases in my .bashrc / .zshrc: eval "$(github-copilot-cli alias -- "$0")" So I could do Is there any official way to get the old syntax back without limiting any new features? Always typing |
Beta Was this translation helpful? Give feedback.
Replies: 6 comments 10 replies
-
You may add the following aliases into your alias '??'='gh copilot suggest -t shell'
alias 'git?'='gh copilot suggest -t git'
alias 'explain'='gh copilot explain' This allows calling e.g. In an upcoming version of the gh version, it will be born with a feature more closely matching the Next technical preview's in terms of aliases for quick execution. |
Beta Was this translation helpful? Give feedback.
-
I'm curious which new version the gh cli has copilot support? I can not find mention of it anywhere in the docs. I'd love to upgrade because my old |
Beta Was this translation helpful? Give feedback.
-
The Next GitHub Copilot CLI technical preview is up and running again! It was an unfortunate oversight when we sunset a few other previews in December that our Copilot CLI also stopped working. We will sunset our Copilot CLI technical preview in the not too far future, once the gh cli extension matures sufficiently. |
Beta Was this translation helpful? Give feedback.
-
It started working for me again after I updated the copilot package:
Maybe they messed up with the old DNS address? |
Beta Was this translation helpful? Give feedback.
-
I've been able to use the |
Beta Was this translation helpful? Give feedback.
-
The ?? Is being handled by the old node @githubnext/github-copilot-cl package would be my guess as when you move to the gh version the alias changes and ?? Is no longer a thing and so you have to recreate it as your own alias as above. |
Beta Was this translation helpful? Give feedback.
You may add the following aliases into your
.bashrc
or.zshrc
:This allows calling e.g.
?? list all files
like with the Next technical preview Copilot CLI. The difference is that you still "accept" by getting the command into your clipboard, at which point you should exit the cli and paste in the command in the shell.In an upcoming version of the gh version, it will be born with a feature more closely matching the Next technical preview's in terms of aliases for quick execution.