-
Notifications
You must be signed in to change notification settings - Fork 850
Open
Open
Feature
Copy link
Labels
Description
Describe the feature or problem you'd like to solve
There is no way to allow or disallow specific files or file types from being viewed and edited by GitHub Copilot.
Proposed solution
Giving complete control over the GitHub Copilot CLI's ability to view and edit files will allow for file operations to be both at their most efficient but also incredibly secure, especially in contexts where the CLI is not being run in interactive mode. Bonus points if view and edit permissions can be managed separately. This feature request should be rolled up as part of #316.
Example prompts or workflows
In interactive mode:
/allow-path # Allow the CLI to see file paths that match this pattern. If any are present, all other paths are disallowed.
/list-paths # List all allowed and disallowed file paths, and allow them to be interactively selected and removed from the list.
/disallow-path # Disallow the CLI from seeing file paths that match this pattern.From the command line (these filters complement the configuration set in interactve mode):
copilot -p "What are the purposes of each .bat file in this repository?" --allow-path *.bat
copilot -p "Identify all the README files in this repository and what they each represent." --allow-path README.md --allow-path */*README.md
copilot -p "Are there any image files in this repository?" --disallow-path *.webp # Find images to compressAdditional context
No response
scarf005