vscode
Agent skill frombadlogic/pi-skills
VS Code integration for viewing diffs and comparing files. Use when showing file differences to the user.
How to install vscode
install vscode
# install the pi-skills pack with the skills CLI
npx skills add badlogic/pi-skills# or add only this skill to Claude Code: copy the folder
vscode/
# into
~/.claude/skills/vscode/ (all projects)
.claude/skills/vscode/ (one project)
1# VS Code CLI Tools23Tools for integrating with VS Code, primarily for viewing diffs.45## Requirements67VS Code must be installed with the `code` CLI available in PATH.89## Opening a Diff1011Compare two files side by side in VS Code:1213```bash14code -d <file1> <file2>15```1617## Git Diffs in VS Code1819### Simple Approach (no config needed)2021Extract the old version to a temp file, then diff:2223```bash24# Compare with previous commit25git show HEAD~1:path/to/file > /tmp/old && code -d /tmp/old path/to/file2627# Compare with specific commit28git show abc123:path/to/file > /tmp/old && code -d /tmp/old path/to/file2930# Compare staged version with working tree31git show :path/to/file > /tmp/staged && code -d /tmp/staged path/to/file32```3334### Gotchas3536- File must exist and have changes between the compared revisions37- Use `git log --oneline -5 -- path/to/file` to verify file has history before diffing3839## When to Use4041- Showing the user what changed in a file42- Comparing two versions of code43- Reviewing git changes visually
Excerpt shown under the repository's MIT license.
