Allow use of system installed Github CLI instead of the bundled installaion (gh.exe)
还没有人认领这个 Issue。
- 主要语言
- Shell
- 星标
- 11.2k
- 派生
- 1.9k
- 平均合并
- 14 小时 16 分钟
- 30 天内合并 PR
- 6
描述
Describe the feature or problem you'd like to solve
Resolve the hard dependency on the bundled Github CLI (gh.exe) by allowing using the system installation
Proposed solution
The current version of copilot app had a hard dependency on the bundled Github CLI (gh.exe).
Unlike copilot.exe and git.exe, there is no environment variable that allow user to override using a system installation.
The result is that, in a company environment that has strict control on where executable can be launched, gh.exe cannot be launched at all.
In an earlier version of copilot app, like 1.0.16, the copilot app still can work fine without major loss of functionality.
With the latest version of copilot app, like 1.1.6, for some reason, I can see toolcall could also result in attempt to trigger gh.exe, and this has no way no disable through a global copilot instruction (such as "do not use gh.exe at all).
Currently, if this happens, under my company environment, it will be caught by our sercutity app and result in an error popup saying something similar to "you have no permission to run gh.exe..." and this cause the copilot app itself stuck in the mid of the task, until I close that popup. (and it will retry opening that gh.exe, which cause this to loop over and over again)
I will expect two things, either:
- Allow copilot to run without launching gh.exe (Im not sure why there is such dependency even my task doesn't need talk to github at all. Maybe auth? but this should be done through copilot-cli already?)
- Allow copilot to read an environment variable to use that gh.exe installation, instead of the bundle one - similar to COPILOT_CLI_PATH. I think this should be the way to go.
Currently, because of this issue, I need to keep myself on a very old version of copilot app. Otherwise, it is completely unusable in my company's environment.
Example prompts or workflows
No response
Additional context
No response
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
首先跟踪现有的 COPILOT_CLI_PATH 处理逻辑,以及启动捆绑 gh.exe 的路径。复现受公司限制的工作流,然后验证是否使用了已配置的系统 GitHub CLI,或者不需要 GitHub 的任务是否可以在不重复启动 gh.exe 的情况下继续执行。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- github, shell
- 领域
- cli
- Issue 类型
- 功能
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 冷清
- 描述清晰度
- 基本清楚
- 新手友好度
- 55/100