-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Open
Labels
Description
Description
If you're a team of people with your code at different paths and want to allow a specific path to be edited, you can do it like this:
"edit": {
"*": "ask",
"some\\path\\to\\file\\**": "allow",
},
```
But this doesn't work, because edit has workspace path (without drive letter) prefixed, like this `src\\some\\path\\to\\file\\file.txt`, so the only solution is to prefix the path with `**` but that's not the same permission I stated above, because it matches ANY prefix to the path.
### Plugins
_No response_
### OpenCode version
1.50.0
### Steps to reproduce
add this to your config
//
"edit": {
"*": "ask",
"test\\**": "allow",
},
```
run `opencode run "write the word FOO to test/permissions.txt"`
This command will fail, reporting that the permission required "ask" access and was auto-rejected, despite explicitly setting it to "Allow" above.
### Screenshot and/or share link
_No response_
### Operating System
Windows 11
### Terminal
WezTerm
Reactions are currently unavailable