-
Notifications
You must be signed in to change notification settings - Fork 1k
Description
Describe the feature or problem you'd like to solve
Add a way to run terminal commands while in a copilot cli session. Something like /term ls to see the current directory's contents. Would make some things easier and faster than asking an AI to do it or opening another terminal.
Proposed solution
I have found there are times when I want to just run a quick command for myself and/or the agent and let it use the info in its context. Rather than tell the agent to run a specific command and tell me what the output is, I sometimes prefer to just run the command myself so I can see what comes out of it, but I'm fine if the agent sees the output too. I think this would be pretty easy for you to support and just makes life a little easier for power users who can think of what to do faster than they can think how to tell an AI how to do it.
I think you could add a slash command like /term or /exec or /run or something super clever. You can include the command run and the output as a comment from the user and use it as context for the agent
Example prompts or workflows
- Sometimes I want to just
lsthe cwd and see the files the agent is seeing. I might also notice we are in the wrong directory and I'd like tocdto the correct one. npm run devdoesn't seem to work when the AI runs it (maybe that's a bug but I assume you don't let it start ongoing processes and leave them hanging?) so I'd like to run it without having to open another terminal/tab.- I have some aliases for multi-step actions I want to take and it would be nice to just do the action, get the result, and let the AI see. Then later I can tell it to add to custom instructions if I need it to do it often. But if I don't, I'd rather just be able to do it from the current terminal.
Additional context
No response