# Verify Command Execution

> verify-command-execution

- Skill: `claudiawong522/verify-command-execution` (Agent Skill)
- Install (CLI): `npx skillmds@latest add claudiawong522/verify-command-execution`
- Raw SKILL.md: https://api.skillmd.com/api/skills/claudiawong522/verify-command-execution/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: claudiawong522 (https://skillmd.com/u/claudiawong522)
- Updated: 2026-09-22
- Page: https://skillmd.com/skills/claudiawong522/verify-command-execution

---

# verify-command-execution

Verify command execution results before proceeding to ensure successful state transitions and catch errors early.

# Verify Command Execution

When executing commands that change system state (like navigation, file creation, or configuration changes), always verify the result before proceeding to the next instruction.

## Why This Matters

State transition commands can fail silently or partially. Verification ensures:
- You're actually in the state you expect
- Errors are caught immediately, not downstream
- Your workflow remains accurate and reliable

## Steps

1. **Execute the state-changing command** (e.g., `cd /path`, `mkdir folder`, `export VAR=value`)
2. **Run a verification command** to confirm the state changed as expected
3. **Check the output** matches your intention
4. **Only then proceed** to the next instruction

## Common Verification Examples

| Command | Verify With |
|---------|------------|
| `cd /some/path` | `pwd` |
| `mkdir new-dir` | `ls -la` or `test -d new-dir && echo "exists"` |
| `export VAR=value` | `echo $VAR` |
| `git checkout branch` | `git branch --show-current` |
| `apt install package` | `which package` or `package --version` |

## Pro Tips

- Use verification commands that are fast and produce clear output
- Don't assume success—always verify
- This adds minimal overhead but saves significant debugging time
- Works especially well when chaining multiple commands

