8000 GitHub - pacak/cargo-prebuilt: Download prebuilt binaries of some crates.io crates
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

pacak/cargo-prebuilt

 
 

Repository files navigation

cargo-prebuilt

Rust Build and Test Rust Checks Crates.io rustc-msrv

Download prebuilt binaries of some crate.io crates.

See supported targets and a list of prebuilt crates here.

(Some targets may not be prebuilt for some crates)

Request a crate to be added here.

How to Use

Cargo prebuilt overwrites existing binaries by default. To stop this use the -s flag, --safe flag, or add safe = true to your config file.

To download a crate: cargo prebuilt CRATE_NAME

To download multiple crates: cargo prebuilt CRATE_1,CRATE_2,CRATE_3,...

To download a version of a crate: cargo prebuilt CRATE_NAME@VERSION

To download multiple crates with versions: cargo prebuilt CRATE_1@V1,CRATE_2,CRATE_3@V3,...

Need help? Try: cargo prebuilt --help or see Config Info

Installation

  • You can download the latest prebuilt binaries of cargo-prebuilt here.
  • Cargo install: cargo install cargo-prebuilt or cargo install cargo-prebuilt --profile=quick-build
  • Cargo prebuilt: cargo prebuilt cargo-prebuilt
  • Cargo binstall: cargo binstall cargo-prebuilt --no-confirm
  • Cargo quickinstall: cargo quickinstall cargo-prebuilt
  • Homebrew: brew install crow-rest/harmless/cargo-prebuilt
  • Install script (unix platforms): curl --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-prebuilt/cargo-prebuilt/main/scripts/install-cargo-prebuilt.sh | bash
  • For github actions you can use cargo-prebuilt/cargo-prebuilt-action

Building

(Cargo prebuilt requires a tls feature)

vendored-openssl (default)

cargo install cargo-prebuilt

native tls (github releases default)

cargo install cargo-prebuilt --no-default-features --features default-native

rustls

cargo install cargo-prebuilt --no-default-features --features default-rustls

rustls with native certs

cargo install cargo-prebuilt --no-default-features --features default-rustls,rustls-native-certs

limit security used

(Cargo prebuilt is tested with default features and may break without the security feature)

Remove security feature included by default, then add the features you want below:

  • sha2: Sha2 hashing
  • sha3: Sha3 hashing
  • sig: Minisign signatures

limit indexes used

(Cargo prebuilt is tested with default features and may break without the indexes feature)

Remove indexes feature included by default, then add the features you want below:

limit color

(Cargo prebuilt is tested with default features and may break without the color feature)

  • Remove the color feature (enabled by default)
  • Or use --no-color, NO_COLOR=true env var, or color = false in the config file.

use mimalloc

cargo install cargo-prebuilt --features mimalloc

Events

To output events use --out.

See Events.

Reports

Reports are generated when a crate is built in the index.

They are stored under $REPORTS/$CRATE/$VERSION by default.

See Report Directory ($REPORTS).

Use --report-path to change where they are stored.

Report Types

Using a custom index

GitHub public

Template (Usually out of date compared to the main index 6311 )

Your url should be formatted like github.com/cargo-prebuilt/index. cargo-prebuilt requires https.

  • export PREBUILT_INDEX=gh-pub:$URL
  • cargo prebuilt --index=gh-pub:$URL CRATES
  • config.toml
    [key.index]
    index = "gh-pub:$URL"
    pub_key = []

GitHub private

Currently in beta!!!

Your url should be formatted like github.com/cargo-prebuilt/index. Cargo-prebuilt requires https.

This index requires an auth token with: Repo permission -> Contents -> Read-only. Generate a token

  • export PREBUILT_INDEX=gh-pri:$URL
  • cargo prebuilt --index=gh-pri:$URL CRATES
  • config.toml
    [key.index]
    index = "gh-pri:$URL"
    pub_key = []
    auth = ""

About

Download prebuilt binaries of some crates.io crates

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Rust 90.4%
  • Shell 4.9%
  • Just 4.7%
0