Shell Overrides
LoopCLI now respects your environment. This guide explains how to change the shell globally and per step.
Detecting your shell
On first run LoopCLI detects the shell from $SHELL (Unix) or COMSPEC (Windows). View the current value with:
loopcli loop shell --show
Setting a global shell
Want to force every CLI step through zsh or fish?
loopcli loop shell --set /bin/zsh
Use loopcli loop shell --reset to fall back to automatic detection.
Per-step overrides
When adding a CLI step you can set a specific shell:
loopcli loop add-cli build "Install deps" npm --arg install --shell /usr/local/bin/fish
The per-step shell takes priority over the global shell.
Background tasks (preview)
Combine shell overrides with background mode (see the background workflows guide) to run dev servers or watchers without blocking the rest of the loop.
Troubleshooting
- Path not found: double-check the shell path exists and is executable.
- Windows PowerShell: set
--set "C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\powershell.exe". - Environment variables: use
--env KEY=valuewhen adding CLI steps to inject shell-specific vars.