Run terminal commands carefully in Copilot agent mode
A VS Code user had Copilot agent mode run shell commands, but it often missed output or got stuck until they changed the shell setup.
- What they did
- A user launched GitHub Copilot agent mode in VS Code from WSL and asked it to work in the terminal. The agent sometimes failed to notice command output or never saw the command finish, so commenters suggested pressing Enter, saving output to a file, adding guidance in copilot-instructions.md, or using a simpler shell instead of themed prompts like Powerlevel10k.
- How it went
- A GitHub engineer later linked the problem to older Powerlevel10k versions and said VS Code fixes were on the way. Even so, people on plain bash and Windows still reported hangs, and in some cases the agent rolled back code that was already correct.
- Tips
- If the agent needs terminal results, keep the shell prompt simple and update Powerlevel10k if you use it. Treat long agent loops as expensive, because failed reads can burn premium requests without making progress.
Try it yourself with GitHub Copilot
In [project path], run [build/test command] in the terminal and fix only the issues that the command reveals. If the terminal output is unclear or the command seems stuck, stop and tell me what you can see instead of guessing. Do not modify code that already passes. Before any irreversible action, such as deleting files, submitting changes, or sending anything, ask me to confirm. When the task is complete, list every file you changed and summarize the command results.
Fill in the [brackets]. Agents can make mistakes, so review anything before it is sent, paid or deleted.
Get 3 agent uses like this every morning
With the day's top AI news. Free, and one click to unsubscribe.
Related agent uses
Let Copilot generate tests and keep rerunning them
A commenter configured GitHub Copilot to keep executing tests and fixing failures until they passed, with a human approving each terminal step.
Run several coding agents from one interface
A developer uses T3 Code to manage multiple coding agents on personal machines, a VPS, and a separate work setup for code changes and writeups.
Design a PR review agent for Azure DevOps
A developer explored how to use GitHub Copilot to review pull requests for Azure DevOps repos, despite Copilot’s built-in review being limited to GitHub.
Set up Copilot to review your PRs, then check for blockers
A developer used GitHub Copilot for PR reviews in a private repo, then found that a large binary file was causing the reviews to fail.
Use Copilot to draft tests and check CI automatically
They let GitHub Copilot create tests and added automated checks in GitHub Actions, which reduced CI failures and sped up merges.
Split development work into phases before using Copilot
A developer plans features in stages first, then feeds the approved steps to GitHub Copilot instead of asking it to make all architecture decisions at once.