Allow copilot-cli to write via tool to only specific files
未关闭
area:permissions
area:tools
- 主要语言
- Shell
- 星标
- 11.2k
- 派生
- 1.9k
- 平均合并
- 14 小时 16 分钟
- 30 天内合并 PR
- 6
描述
### Describe the feature or problem you'd like to solve
When the copilot write tool option is allowed it gives access to all files
### Proposed solution
Allow to restrict the scope the model is allowed to write to, for example with directories or files
```bash
copilot --allow-tool 'write(foo.txt)' --allow-tool 'write(bar/)'
```
This is similar to the shell tool option that is already supported https://docs.github.com/en/copilot/concepts/agents/about-copilot-cli#using-the-approval-options
```
copilot --deny-tool 'shell(git push)'
```
### Example prompts or workflows
```bash
copilot --allow-tool 'write(foo.txt)' --allow-tool 'write(bar/)'
```
### Additional context
_No response_
贡献指南
评估
这个 Issue 还没有评估数据。