Shell Configuration Skill
Unified skill for Fish and Zsh shell configuration. Detect the target shell first, then load the appropriate reference.
Reference Loading Table
| Shell |
Signal |
Load |
Why |
| Fish |
Any Fish context |
fish-shell-config.md |
Full Fish config patterns, syntax, file layout |
| Fish |
Migrations from Bash |
fish-bash-migration.md |
Bash-to-Fish syntax translation |
| Fish |
Variable scope, PATH, abbr, completions |
fish-quick-reference.md |
Variable scope guide, special variables, control flow |
| Fish |
Error audit, broken config |
fish-preferred-patterns.md |
Failure modes with grep detection and error-fix mappings |
| Fish |
Dev tool integration |
fish-tool-integrations.md |
Fish integration patterns for Go, Rust, Node, Python, Docker |
| Zsh |
Any Zsh context |
zsh-shell-config.md |
Full Zsh config patterns, RC files, frameworks, hooks |
| Zsh |
Migrations from Bash |
zsh-bash-migration.md |
Bash-to-Zsh syntax translation |
| Zsh |
Variable scoping, expansion flags, special vars |
zsh-quick-reference.md |
Parameter expansion flags, special variables |
| Zsh |
Error audit, slow startup, glob errors |
zsh-preferred-patterns.md |
Failure modes with grep detection and error-fix mappings |
| Zsh |
Dev tool integration |
zsh-tool-integrations.md |
Zsh integration patterns for Go, Rust, Node, Python, Docker |
Instructions
Step 1: Detect Shell Type
Before loading references or writing code, determine the target shell:
- Fish:
$SHELL contains fish, target file has .fish extension, or target directory is ~/.config/fish/
- Zsh:
$SHELL contains zsh, target file is .zshrc/.zshenv/.zprofile, or has .zsh extension
If neither Fish nor Zsh, this skill does not apply.
Step 2: Load Shell-Specific Reference
Load the appropriate reference file from the table above based on the detected shell and the task signal. Start with the full config reference (fish-shell-config.md or zsh-shell-config.md), then load additional references as needed.
Step 3: Follow Shell-Specific Patterns
Each reference contains complete instructions for that shell. Follow them exactly — Fish and Zsh have incompatible syntax in many areas (variable assignment, PATH handling, conditionals, completions).
Key differences:
| Concept |
Fish |
Zsh |
| Variable assignment |
set -gx VAR value |
export VAR=value |
| PATH management |
fish_add_path |
typeset -U path; path=(...) |
| Completions |
completions/ directory |
compinit + fpath |
| Conditionals |
test, not [[ ]] |
[[ ]] preferred |
| Functions |
function name ... end |
function name { ... } |
| Interactive guard |
status is-interactive |
[[ -o interactive ]] |
1---2name: shell-config3description: Shell configuration: Fish and Zsh setup, PATH, completions, plugins.4---5
6# Shell Configuration Skill
7
8Unified skill for Fish and Zsh shell configuration. Detect the target shell first, then load the appropriate reference.
9
10## Reference Loading Table
11
12| Shell | Signal | Load | Why |
13|---|---|---|---|
14| Fish | Any Fish context | `fish-shell-config.md` | Full Fish config patterns, syntax, file layout |
15| Fish | Migrations from Bash | `fish-bash-migration.md` | Bash-to-Fish syntax translation |
16| Fish | Variable scope, PATH, abbr, completions | `fish-quick-reference.md` | Variable scope guide, special variables, control flow |
17| Fish | Error audit, broken config | `fish-preferred-patterns.md` | Failure modes with grep detection and error-fix mappings |
18| Fish | Dev tool integration | `fish-tool-integrations.md` | Fish integration patterns for Go, Rust, Node, Python, Docker |
19| Zsh | Any Zsh context | `zsh-shell-config.md` | Full Zsh config patterns, RC files, frameworks, hooks |
20| Zsh | Migrations from Bash | `zsh-bash-migration.md` | Bash-to-Zsh syntax translation |
21| Zsh | Variable scoping, expansion flags, special vars | `zsh-quick-reference.md` | Parameter expansion flags, special variables |
22| Zsh | Error audit, slow startup, glob errors | `zsh-preferred-patterns.md` | Failure modes with grep detection and error-fix mappings |
23| Zsh | Dev tool integration | `zsh-tool-integrations.md` | Zsh integration patterns for Go, Rust, Node, Python, Docker |
24
25## Instructions
26
27### Step 1: Detect Shell Type
28
29Before loading references or writing code, determine the target shell:
30
31- **Fish**: `$SHELL` contains `fish`, target file has `.fish` extension, or target directory is `~/.config/fish/`
32- **Zsh**: `$SHELL` contains `zsh`, target file is `.zshrc`/`.zshenv`/`.zprofile`, or has `.zsh` extension
33
34If neither Fish nor Zsh, this skill does not apply.
35
36### Step 2: Load Shell-Specific Reference
37
38Load the appropriate reference file from the table above based on the detected shell and the task signal. Start with the full config reference (`fish-shell-config.md` or `zsh-shell-config.md`), then load additional references as needed.
39
40### Step 3: Follow Shell-Specific Patterns
41
42Each reference contains complete instructions for that shell. Follow them exactly — Fish and Zsh have incompatible syntax in many areas (variable assignment, PATH handling, conditionals, completions).
43
44**Key differences**:
45
46| Concept | Fish | Zsh |
47|---------|------|-----|
48| Variable assignment | `set -gx VAR value` | `export VAR=value` |
49| PATH management | `fish_add_path` | `typeset -U path; path=(...)` |
50| Completions | `completions/` directory | `compinit` + `fpath` |
51| Conditionals | `test`, not `[[ ]]` | `[[ ]]` preferred |
52| Functions | `function name ... end` | `function name { ... }` |
53| Interactive guard | `status is-interactive` | `[[ -o interactive ]]` |