Installation
stacy is a single static binary with no runtime dependencies.
Quick Install
macOS / Linux:
curl -fsSL https://raw.githubusercontent.com/janfasnacht/stacy/main/install.sh | bash
Windows (PowerShell):
irm https://raw.githubusercontent.com/janfasnacht/stacy/main/install.ps1 | iex
Both install to ~/.local/bin/ (or equivalent). Ensure this directory is in your PATH.
Other Methods
Homebrew:
brew install janfasnacht/stacy/stacy
Cargo (from source):
cargo install --git https://github.com/janfasnacht/stacy.git
Manual download: Get binaries from the releases page.
Verify Installation
stacy --version # Check version
stacy doctor # Check Stata detection and configuration
Stata Detection
stacy automatically finds Stata in common locations:
| Platform | Searched paths |
|---|---|
| macOS | /Applications/Stata*/, /Applications/StataNow/ |
| Linux | /usr/local/stata*, ~/stata* |
| Windows | C:\Program Files\Stata*\ |
If Stata is elsewhere, configure via (in precedence order):
- CLI flag:
stacy run --engine /path/to/stata-mp script.do - Environment:
export STATA_BINARY=/path/to/stata-mp - Config file:
~/.config/stacy/config.toml
Troubleshooting
Common installation issues:
| Problem | Solution |
|---|---|
stacy: command not found | Add ~/.local/bin to PATH, restart terminal |
| macOS blocks binary | Run xattr -d com.apple.quarantine ~/.local/bin/stacy |
| Stata not found | Set STATA_BINARY env var or config file |
See Troubleshooting for detailed solutions.
Updating
Re-run the install command, or:
brew upgrade stacy # Homebrew
cargo install ... --force # Cargo
Update Notifications
stacy checks for new releases on startup and prints a notification to stderr if one is available:
Update available: v0.1.0 → v0.2.0
Run `brew upgrade stacy` to update
The check uses a local cache refreshed every 24 hours in the background. It never slows down commands.
Update notifications are automatically suppressed in CI environments, non-interactive sessions, and piped output. To disable globally, set update_check = false in ~/.config/stacy/config.toml or set the STACY_NO_UPDATE_CHECK environment variable.
Uninstalling
rm ~/.local/bin/stacy # Remove binary
rm -rf ~/.config/stacy # Remove config (optional)
rm -rf ~/.cache/stacy # Remove package cache (optional)
Next Steps
- Quick Start - Run your first script
- stacy doctor - Troubleshoot detection issues