A powerful command-line tool for automating the release process of Rust crates and workspaces on crates.io, with support for package manager formula generation.
- 🚀 Automated Version Management: Automatically increment versions for crates and workspaces
- 🌐 Workspace Support: Handle complex workspace releases with dependency management
- 📦 Package Manager Integration: Generate Homebrew formulas and Scoop manifests
- 🔧 Flexible Publishing Options: Control publishing with various flags and options
- ⏱️ Smart Delay Handling: Built-in delays between crate publications to ensure proper indexing
- 🛠️ Non-publish Mode: Change crate(s) verisions, commit and git without actually publishing to crates.io
- 📝 Automatic Git Integration: Commit changes, create tags, and push to remote repositories
- 🎨 Shell Completions: Generate autocompletion scripts for your shell
cargo install releaser
git clone https://github.com/aegoroff/releaser.git cd releaser cargo install --path .
Releaser provides several subcommands for different release scenarios:
Release all crates in a workspace with automatic version increment and dependency management:
# Release a workspace with minor version increment releaser w minor /path/to/workspace # Release with a 30-second delay between crate publications releaser w patch /path/to/workspace -d 30 # Release without actually publishing to crates.io (dry run) releaser w major /path/to/workspace --nopublish
Release a single crate with version increment:
# Release a single crate with patch version increment releaser c patch /path/to/crate # Release with all features enabled releaser c minor /path/to/crate -a # Release without verification releaser c major /path/to/crate -n
Generate package manager formulas for distributing your binaries:
# Generate a Homebrew formula
releaser b \
--crate /path/to/crate \
--linux /path/to/linux/binary \
--macos /path/to/macos/binary \
--base https://github.com/user/repo/releases/download/vX.Y.Z# Generate a Scoop manifest
releaser s \
--crate /path/to/crate \
--binary /path/to/windows/binary \
--exe myapp.exe \
--base https://github.com/user/repo/releases/download/vX.Y.ZRelease all crates in a workspace.
releaser w [OPTIONS] <INCR> <PATH>
Arguments:
<INCR>: Version increment. One of:major,minor, orpatch<PATH>: Path to the workspace root
Options:
-d, --delay <NUMBER>: Delay in seconds between publishing crates (default: 20)-a, --all: Enable all features when publishing-n, --noverify: Skip verification when publishing--nopublish: Skip publishing, only update versions and Git operations
Release a single crate.
releaser c [OPTIONS] <INCR> <PATH>
Arguments:
<INCR>: Version increment. One of:major,minor, orpatch<PATH>: Path to the crate root
Options:
-a, --all: Enable all features when publishing-n, --noverify: Skip verification when publishing--nopublish: Skip publishing, only update versions and Git operations
Create a Homebrew formula for macOS and Linux packages.
releaser b [OPTIONS] --crate <PATH> --base <URI>
Options:
-c, --crate <PATH>: Path to the crate where Cargo.toml is located-l, --linux <PATH>: Path to the Linux package directory-m, --macos <PATH>: Path to the macOS x64 package directory-a, --macosarm <PATH>: Path to the macOS ARM64 package directory-b, --base <URI>: Base URI for downloaded artifacts-u, --output [<PATH>]: File path to save result (stdout if not set)
Create a Scoop manifest for Windows packages.
releaser s [OPTIONS] --crate <PATH> --binary <PATH> --exe <FILE> --base <URI>
Options:
-c, --crate <PATH>: Path to the crate where Cargo.toml is located-i, --binary <PATH>: Path to the 64-bit binary package directory-e, --exe <FILE>: Windows executable name-b, --base <URI>: Base URI for downloaded artifacts-u, --output [<PATH>]: File path to save result (stdout if not set)
Generate autocompletion scripts for your shell.
releaser completion <SHELL>
Supported shells: bash, elvish, fish, powershell, zsh
Collect system information for bug reports.
releaser bugreport
# 1. Release a workspace with minor version increment releaser w minor /path/to/my/workspace # 2. Release with custom delay and all features releaser w patch /path/to/my/workspace -d 60 -a # 3. Test release without publishing releaser w major /path/to/my/workspace --nopublish
# Release a single crate with patch increment releaser c patch /path/to/my/crate # Release with all features and no verification releaser c minor /path/to/my/crate -a -n
# Generate Homebrew formula releaser b \ --crate ./my-app \ --linux ./artifacts/linux \ --macos ./artifacts/macos \ --base https://github.com/user/my-app/releases/download/v1.0.0 \ --output my-app.rb # Generate Scoop manifest releaser s \ --crate ./my-app \ --binary ./artifacts/windows \ --exe my-app.exe \ --base https://github.com/user/my-app/releases/download/v1.0.0 \ --output my-app.json
Contributions are welcome! Here's how you can help:
- Fork the repository
- Create a new branch for your feature or bug fix
- Make your changes and write tests
- Ensure all tests pass with
cargo test - Submit a pull request with a clear description of your changes
# Clone the repository git clone https://github.com/aegoroff/releaser.git cd releaser # Run tests cargo test # Build the project cargo build # Install from source cargo install --path .
This project uses rustfmt for code formatting. Please ensure your code is properly formatted:
cargo fmt
This project is licensed under the MIT License - see the LICENSE.txt file for details.
Copyright (c) 2021-2026 Alexander Egorov
- cargo-release - Another cargo subcommand for package release
- cargo-workspaces - Cargo subcommand for managing workspace versions