github / github/copilot-cli

Permissions from .claude/settings.json not taken into account (also in v1.0.12!)

未关闭
#2,338 3 条评论 2 个 reaction 已指派 0 人 在 GitHub 查看
area:configuration area:permissions
主要语言
Shell
星标
11.2k
派生
1.9k
平均合并
14 小时 16 分钟
30 天内合并 PR
6

描述

### Describe the bug

Release notes for v1.0.12 say:

> Read .claude/settings.json and .claude/settings.local.json as additional repo config sources

With following `.claude/settings.json`:

```json
{
"$schema": "https://json.schemastore.org/claude-code-settings.json",
"permissions": { "allow": ["Bash(npx eslint)"] }
}
```

Asking copilot to run npx eslint still pops up a permission question to the user.

Running `copilot --allow-tool='shell(npx eslint)'` does work as expected however.

### Affected version

GitHub Copilot CLI 1.0.12

### Steps to reproduce the behavior

1. Put following json in `.claude/settings.json`:
```json
{
"$schema": "https://json.schemastore.org/claude-code-settings.json",
"permissions": { "allow": ["Bash(npx eslint)"] }
}
```
2. Run `copilot`
3. Ask "please run npx eslint"
4. Observe that copilot asks the user for permission

### Expected behavior

Copilot should not ask the user for permission, just like when running `copilot --allow-tool='shell(npx eslint)'`

### Additional context

OS: Windows
Terminal: Windows Terminal
Shell: Git Bash and Powershell (both tested)

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。