Troubleshooting
This guide covers common issues and their solutions.
Shell Integration & Reactive Themes
Section titled “Shell Integration & Reactive Themes”CRT supports reactive themes that respond to terminal events like command success/failure. This requires shell integration via OSC 133 semantic prompts.
Powerlevel10k / Oh-My-Zsh Users
Section titled “Powerlevel10k / Oh-My-Zsh Users”If you use Powerlevel10k (p10k) with Oh-My-Zsh, CRT’s default shell integration can cause issues:
- PATH ordering problems - paths from
.zshenv(like cargo) end up at the end - Reactive themes not triggering - hook conflicts with p10k
Solution: Use p10k’s native OSC 133 support instead of CRT’s:
-
Disable CRT’s semantic prompts in
~/.config/crt/config.toml:[shell]semantic_prompts = false -
Enable p10k’s shell integration by adding to
~/.p10k.zsh:Terminal window typeset -g POWERLEVEL9K_TERM_SHELL_INTEGRATION=true -
Clear p10k’s instant prompt cache:
Terminal window rm -f ~/.cache/p10k-instant-prompt-*.zsh -
Restart CRT
Reactive Themes Not Working
Section titled “Reactive Themes Not Working”If reactive themes (like nyancat-responsive or robco-reactive) don’t respond to command success/failure:
-
Check shell integration is enabled - either via CRT’s
semantic_prompts = trueor p10k’sPOWERLEVEL9K_TERM_SHELL_INTEGRATION=true -
Test OSC 133 is working - launch CRT from terminal with debug logging:
Terminal window RUST_LOG=debug /Applications/crt.app/Contents/MacOS/crtLook for
TerminalEvent::CommandSuccessorTerminalEvent::CommandFailin the terminal output where you launched CRT (not inside CRT itself). -
Verify theme has event handlers - check your theme CSS for
:terminal::on-command-successand:terminal::on-command-failselectors
Shell Starts with Exit Code 1
Section titled “Shell Starts with Exit Code 1”If your shell prompt shows a non-zero exit code immediately on startup (before running any commands):
This usually means something in your shell initialization is returning an error. Common causes:
-
unaliascommands for aliases that don’t exist - add|| true:Terminal window unalias foo 2>/dev/null || true -
Missing commands in plugins - disable unused oh-my-zsh plugins (e.g.,
systemd,ubuntuon macOS) -
Failed conditionals - ensure the last command in your
.zshrcreturns 0
To debug, run:
zsh -xc 'source ~/.zshrc' 2>&1 | grep -i errorSprite & Asset Issues
Section titled “Sprite & Asset Issues”Sprite Not Loading
Section titled “Sprite Not Loading”If sprites don’t appear or you see path errors in logs:
-
Check the sprite path - paths in CSS are relative to the theme directory:
/* If sprite is at ~/.config/crt/themes/mytheme/sprites/cat.png */--sprite-path: "sprites/cat.png"; -
Verify assets were installed - check
~/.config/crt/themes/contains sprite subdirectories -
Check file permissions - sprite files must be readable
Theme Hot Reload Not Working
Section titled “Theme Hot Reload Not Working”If editing theme CSS doesn’t update the terminal:
- Save the file - some editors use atomic saves that the watcher may miss
- Check the file path - hot reload only works for themes in
~/.config/crt/themes/ - Restart CRT if hot reload seems stuck
Performance Issues
Section titled “Performance Issues”High CPU Usage
Section titled “High CPU Usage”- Disable unused effects - complex effects like
matrixorparticlesuse GPU - Reduce effect intensity - lower particle counts, star counts, etc.
- Check for animation loops - infinite sprite animations consume resources
Slow Startup
Section titled “Slow Startup”- Check shell initialization - CRT’s startup time includes shell init
- Disable p10k instant prompt temporarily to isolate the issue
- Review oh-my-zsh plugins - many plugins slow down shell startup
macOS-Specific Issues
Section titled “macOS-Specific Issues”App Killed After Manual Binary Update
Section titled “App Killed After Manual Binary Update”If you manually replace the binary in /Applications/crt.app/Contents/MacOS/crt, macOS may kill it due to invalid code signature.
Solution: Re-sign the app:
sudo codesign --force --deep --sign - /Applications/crt.appAccessibility Permissions
Section titled “Accessibility Permissions”Some features may require accessibility permissions. Grant them in: System Preferences > Security & Privacy > Privacy > Accessibility
Getting Help
Section titled “Getting Help”If your issue isn’t covered here:
-
Check logs - launch CRT from terminal with
RUST_LOG=debug(logs appear in the terminal where you launched, not inside CRT):Terminal window RUST_LOG=debug /Applications/crt.app/Contents/MacOS/crt -
Search existing issues - https://github.com/colliery-io/crt/issues
-
Open an issue - include relevant logs, your config, and steps to reproduce