Installation
This guide provides detailed instructions for installing RustyHook on different platforms.
Prerequisites
- Rust and Cargo: Required if installing via Cargo
- Git: Required for version control integration
Installation Methods
Using Cargo (Recommended)
The simplest way to install RustyHook is using Cargo, Rust's package manager:
cargo install rustyhook
This will download, compile, and install the latest version of RustyHook.
Using Package Managers
Homebrew (macOS and Linux)
brew install rustyhook
Chocolatey (Windows)
choco install rustyhook
Scoop (Windows)
scoop install rustyhook
Manual Installation
If you prefer to build from source:
-
Clone the repository:
git clone https://github.com/your-org/rustyhook.git
-
Navigate to the directory:
cd rustyhook
-
Build the project:
cargo build --release
-
The binary will be available at
./target/release/rustyhook
-
(Optional) Add to your PATH:
# On Unix-like systems cp ./target/release/rustyhook /usr/local/bin/ # On Windows, move to a directory in your PATH or add the release directory to your PATH
Verifying Installation
To verify that RustyHook is installed correctly:
rustyhook --version
# or using the alias
rh --version
Updating RustyHook
To update to the latest version:
cargo install rustyhook --force
Uninstalling
To uninstall RustyHook:
cargo uninstall rustyhook
Troubleshooting
Common Issues
- Command not found: Ensure the installation directory is in your PATH
- Permission denied: You may need to use
sudo
on Unix-like systems - Compilation errors: Make sure you have the latest version of Rust and Cargo
Getting Help
If you encounter any issues during installation, please:
- Check the FAQ for common problems
- Search for existing issues on the GitHub repository
- Open a new issue if your problem hasn't been reported
Next Steps
After installation, you might want to:
- Get started with RustyHook
- Learn about CLI usage
- Set up shell completions