Appendix: Terminal Quick Reference
The Problem
You're in the terminal, and something isn't working. Maybe a command is stuck. Maybe you typed something wrong and want to start over. Maybe you're not sure which folder you're in.
This reference helps you recover from common situations and navigate with confidence.
The Key Idea
Core concept
The terminal remembers your history and helps you avoid retyping. A few keyboard shortcuts let you work faster and recover from mistakes.
Choosing a Terminal App
Your computer comes with a built-in terminal, but better options exist:
macOS:
- Built-in Terminal — Works fine to start
- iTerm2 — More features, split panes, better search
- Ghostty — Fast, modern, GPU-accelerated
Windows:
- WSL (Windows Subsystem for Linux) — Run a real Linux environment inside Windows. Recommended for the best compatibility with
tdxand developer tools.
Linux:
- Most distributions include excellent terminals by default
When Things Go Wrong
These three shortcuts handle most "I'm stuck" situations:
| Shortcut | When to Use It |
|---|---|
ctrl + c | Something is running and you want to stop it |
ctrl + k | Clear everything from cursor to end of line |
ctrl + l | The screen is cluttered and you want a fresh view |
up arrow | You want to repeat or edit your last command |
Editing Commands
Mistyped something? These shortcuts let you fix it without retyping:
| Shortcut | What It Does |
|---|---|
ctrl + a | Jump to the beginning of the line |
ctrl + e | Jump to the end of the line |
ctrl + w | Delete the last word you typed |
ctrl + u | Clear everything you've typed |
Finding Things
| Shortcut | What It Does |
|---|---|
tab | Auto-complete a filename (type first few letters, then press tab) |
ctrl + r | Search your command history (start typing to find past commands) |
Where Am I? What's Here?
When you're disoriented, these commands help:
| Command | What It Tells You |
|---|---|
pwd | Your current location (which folder you're in) |
ls | What files and folders are here |
ls -la | Same, but with more detail (size, dates, hidden files) |
Moving Around
| Command | Where It Takes You |
|---|---|
cd foldername | Into a folder |
cd .. | Up one level (to the parent folder) |
cd ~ | Back to your home directory |
Looking at Files
| Command | What It Does |
|---|---|
cat filename | Show the entire file contents |
less filename | View a long file (use arrow keys to scroll, q to quit) |
Working with Files
| Command | What It Does | Example |
|---|---|---|
cp | Copy a file | cp segment.yml backup.yml |
mv | Move or rename a file | mv draft.yml final.yml |
rm | Delete a file | rm old-segment.yml |
mkdir | Create a new folder | mkdir segments |
Searching
| Command | What It Does | Example |
|---|---|---|
grep | Find text inside files | grep "high-value" *.yml |
Getting Help
Any command will explain itself:
tdx --help # See all tdx commands
tdx sg --help # See segment commands
tdx journey --help # See journey commandsCommon tdx Commands
For full details, see the Commands Reference.
| Command | What It Does |
|---|---|
tdx sg pull | Download segments from server |
tdx sg push | Upload your changes |
tdx sg validate | Check your YAML before pushing |
tdx journey pull | Download journeys from server |
tdx journey push | Upload journey changes |
tdx claude | Start AI assistant |
What You've Learned
You now have a reference for recovering from common terminal situations. You don't need to memorize these—bookmark this page and return when you need it.
The terminal becomes familiar with practice. Each time you use tab to auto-complete or up arrow to recall a command, you're building muscle memory that makes the next task faster.