29 releases

0.3.5 Nov 12, 2024
0.3.2 Oct 2, 2024
0.2.10 Nov 18, 2023
0.2.9 Mar 14, 2023
0.1.3 Nov 30, 2020

#40 in Cargo plugins

Download history 1949/week @ 2024-08-18 2564/week @ 2024-08-25 3909/week @ 2024-09-01 4036/week @ 2024-09-08 2221/week @ 2024-09-15 3179/week @ 2024-09-22 3251/week @ 2024-09-29 3979/week @ 2024-10-06 2590/week @ 2024-10-13 2848/week @ 2024-10-20 2261/week @ 2024-10-27 3562/week @ 2024-11-03 4254/week @ 2024-11-10 2441/week @ 2024-11-17 3206/week @ 2024-11-24 2055/week @ 2024-12-01

12,574 downloads per month

MIT/Apache

47KB
1K SLoC

cargo-quickinstall

Crates.io Join the chat at https://gitter.im/cargo-quickinstall/community

cargo-quickinstall is a bit like Homebrew's concept of Bottles (binary packages), but for cargo install.

Installation

cargo install cargo-quickinstall

Recent versions of Windows, MacOS and Linux are supported.

Usage

Whenever you would usually write something like:

cargo install ripgrep

you can now write:

cargo quickinstall ripgrep

This will install pre-compiled versions of any binaries in the crate. If we don't have a pre-compiled version, it will fallback to cargo install automatically.

Relationship to cargo-binstall

cargo-binstall (from version 0.6.2 onwards) is also capable of fetching packages from the cargo-quickinstall github releases repo. cargo-binstall is an excellent piece of software. If you're looking for something for desktop use, I can recommend using cargo-binstall.

Use in CI systems

If you want to install a rust package on a CI system, you can do it with a curl | tar command, directly from the cargo-quickinstall github releases repo.

$ cargo-quickinstall --dry-run ripgrep

will print:

"curl" "--user-agent" "cargo-quickinstall client (alsuren@gmail.com)" "--location" "--silent" "--show-error" "--fail" "https://github.com/cargo-bins/cargo-quickinstall/releases/download/ripgrep-13.0.0-x86_64-apple-darwin/ripgrep-13.0.0-x86_64-apple-darwin.tar.gz" | "tar" "-xzvvf" "-" "-C" "/Users/alsuren/.cargo/bin"

Edit the command however you need, and paste it into your CI pipeline.

Supported targets

Check supported-targets for lists of targets quickinstall can build for.

Limitations

Non-default features are not supported.

The cargo-quickinstall client is just a glorified bash script at this point.

Currently it assumes that you have access to:

  • tar
  • curl

Both of these should exist on all recent Windows and MacOS installs. curl is available on most Linux systems, and is assumed to exist by the rustup installation instructions. I only plan to remove these runtime dependencies if it can be done without increasing how long cargo install cargo-quickinstall takes (might be possible to do this using feature flags?).

There are a few pieces of infrastructure that are also part of this project:

  • A server for distributing the pre-built binaries
    • We are using github releases for this.
  • A server for report gathering
    • This is done using a vercel server that saves counts to redis.
  • A periodic task for building the most-requested packages for each OS/architecture
    • Get someone to audit my GitHub Actions sandboxing scheme.

Contributing

There are a lot of things to figure out at the moment, so now is the perfect time to jump in and help. I created a Gitter room for collaborating in. You can also poke @alsuren on Twitter or Discord. I'm also up for pairing over zoom to get new contributors onboarded.

Work is currently tracked on the kanban board. If you want help breaking down a ticket, give me a shout in one of the above places.

Releasing

Releasing of patch versions is handled by the makefile, so can be done by:

make release

If you need to make a major version bump then copy-paste the commands out of the Makefile.

Once a release has been made, post about it on the rust forums, reddit and twitter.

License

Copyright (c) 2020-2022 cargo-quickinstall developers

cargo-quickinstall is made available under the terms of either the MIT License or the Apache License 2.0, at your option.

See the LICENSE-APACHE and LICENSE-MIT files for license details.

Dependencies

~2–10MB
~125K SLoC