Instant tools. Instant builds. One command.
Project description
Soldr / Rust
A tool to download rust tool sets and aggressive cache your build. Instant warm compiles. Gh and local builds. Just add soldr before all your build commands
Rendered benchmarks: zackees.github.io/soldr
Instant tools. Instant builds. One command.
soldr = crgx + zccache in a single tool.
Where correct builds meet instant builds.
The point of soldr is not to invent some brand-new primitive. The point is to combine the pieces that already work into one tool that people can actually rely on every day.
zccache is already excellent. crgx already proved the value of instant Rust tooling. soldr turns those into one front door:
- get the right Rust tool for the job
- get the right Windows ABI without thinking about it
- get transparent compilation caching without separate setup
That is the same reason uv is compelling. uv did not win because it invented packaging, virtual environments, or Python installation. It won because it made the whole workflow feel like one tool instead of a pile of separate ones.
soldr aims for the same outcome in the Rust toolchain world.
Current release line:
0.5.xis the secure front-door, tool-fetch, and built-in zccache-backed cache release line1.0.0-rcremains reserved for broader release hardening and bootstrap validation- the supported external integration boundary remains the
soldrexecutable, not the internal Rust crates; see docs/API_BOUNDARY.md - practical integration examples for local builds and GitHub Actions live in INTEGRATION.md
Install from npm
npm install -g @zackees/soldr
soldr --version
The npm package is a small launcher that downloads the matching soldr GitHub
Release binary for your OS and architecture during install, verifies it against
the published SHA256SUMS file, and exposes the soldr command.
GitHub Actions setup
The current GitHub Actions entry point is the public setup-soldr action:
- uses: zackees/setup-soldr@v0
with:
cache: true
- run: soldr cargo build --locked --release
- run: soldr cargo test --locked
That action:
- installs
soldr - bootstraps
rustupinto the cached runner-local root when the runner does not already have it - preinstalls the exact Rust toolchain from
rust-toolchain.tomlby default viarustup - restores a cacheable runner-local root for Soldr, Cargo, and rustup state
- restores and saves the Soldr-owned zccache compilation artifact cache under
SOLDR_CACHE_DIRby default; setbuild-cache: falseto disable it - restores and saves a zccache-owned Rust artifact plan cache by default for no-op CI fast paths; set
target-cache: falseto disable it ortarget-cache-mode: fullto opt into explicit whole-target caching - puts
soldronPATHfor later steps
For existing workflows where rewriting every cargo ... command is high-friction, opt into Cargo PATH shims:
- uses: zackees/setup-soldr@v0
with:
tool-shims: cargo
- run: cargo build --locked --release
- run: cargo test --locked
The shim mode is off by default. When enabled, the action resolves the real Cargo binary before prepending its shim directory, then exports that real path for Soldr so cargo ... can safely trampoline into soldr cargo ... without recursive PATH lookup.
If your project pins Rust in rust-toolchain.toml, let the action read that file or pass the exact value with toolchain:. Do not preinstall a different generic toolchain such as stable and assume soldr will reconcile it later. The action exports RUSTUP_TOOLCHAIN after installation so later cargo, rustc, and soldr cargo ... steps stay on the toolchain it just installed instead of asking rustup to resolve a pinned file lazily.
On GitHub-hosted runners, this means you usually do not need a separate toolchain setup action for the normal path. The action still uses rustup under the hood today, but it bootstraps rustup itself when the runner does not already have it.
On runners without rustup, the action downloads and installs it into the cached runner-local root before provisioning the requested toolchain.
The public action lives in zackees/setup-soldr and is generated from this repository's root action source. This repository dogfoods zackees/setup-soldr@v0 in setup-soldr-action.yml. For fuller examples and fallback patterns, see INTEGRATION.md.
CI cache lineage
GitHub Actions caches are not shared across arbitrary sibling feature branches. A workflow run can restore caches from its own branch, the default branch, and for pull requests the PR base branch. It cannot directly restore caches created on another feature branch.
That means Soldr treats main as the canonical warm-cache source:
- CI runs on pushes to
mainand feature branches. - A feature-branch push can save a branch-local cache entry in its own branch scope.
- Later pushes and PRs for that same branch restore that branch-local cache first.
- If the feature branch has no exact cache yet, GitHub falls back to the
maincache lineage through the same stable keys. - The heavy cache-producing CI runs on branch pushes, not
pull_request, so each feature branch gets one useful cache lineage instead of a duplicate PR merge-ref lineage.
In practice this gives the exact parent/child model we want: main acts as the shared parent cache, feature branches read from that parent on miss, and each feature branch may also save its own preferred child cache when the workflow runs on push. Pull requests then reflect the branch-push CI state instead of creating a second heavy cache path. This repository is the first reference implementation of that pattern. For the full wiring and rollout notes, see docs/CI_CACHE.md.
Why soldr exists
On Windows, the real problem is not "how do I cache builds?" or "how do I download a tool binary?" in isolation.
The real problem is that the execution path is messy:
- the wrong
cargocan win onPATH - the wrong Windows target can get selected
- GNU can leak in where MSVC should have been used
- users end up debugging their toolchain instead of shipping code
soldr exists to make that path boring.
When you run soldr, the tool should do the obvious thing:
- pick MSVC on Windows by default
- fetch the tool you asked for
- cache it locally
- fetch and manage zccache so Rust builds get transparent caching without manual wrapper setup
If soldr solves that one problem well, it becomes a super tool: the command you reach for first, because it makes the rest of the stack behave.
-
Tool acquisition (the crgx half): Need
maturin,cargo-dylint, or any crate binary? soldr fetches a pre-built binary from GitHub Releases in seconds. Nocargo installfrom source. Cached locally for instant reuse. On0.5.x, this is still an upstream trust decision rather than a repo-side trust guarantee; see docs/TRUST_BOUNDARIES.md. -
Compilation caching (the zccache half):
soldr cargo ...now fetches and manages a pinnedzccacherelease for Rust builds. soldr owns the zccache daemon/session wiring and keeps managed zccache artifacts under Soldr's cache root.
# Build through soldr's front door:
soldr cargo build --release
soldr cargo test
soldr --no-cache cargo test
soldr purge
SOLDR_RUSTC_WRAPPER=sccache soldr cargo build
SOLDR_RUSTC_WRAPPER=none soldr cargo build
# Fetch and run any Rust tool instantly:
soldr maturin build --release
soldr cargo-dylint check
soldr rustfmt src/main.rs
How it works
soldr cargo build --release
+-- resolve the real cargo binary
+-- on Windows, re-run from a soldr-owned runtime copy when needed
+-- fetch/start managed zccache when cache is enabled
+-- set soldr as the compiler wrapper for this build
+-- have soldr wrapper mode delegate to managed zccache
+-- delegate to cargo with your existing flags
soldr maturin build --release
+-- maturin cached? --> run instantly
+-- not cached? --> download pre-built binary (2s) --> run
Linker speed (the other half of fast CI)
soldr caches rustc invocations. It does not cache the linker step. If your build links many binaries (multiple tests/*.rs files, several [[bin]] targets, examples, benches), the dominant cost is often ld, and zccache will not help with that.
On Linux, switch to the mold linker for ~5-10x faster linking. Add to your repo's .cargo/config.toml:
[target.x86_64-unknown-linux-gnu]
linker = "clang"
rustflags = ["-C", "link-arg=-fuse-ld=mold"]
[target.x86_64-unknown-linux-musl]
linker = "clang"
rustflags = ["-C", "link-arg=-fuse-ld=mold"]
Then in CI, install mold before any cargo step:
- name: Install mold linker
run: |
sudo apt-get update
sudo apt-get install -y --no-install-recommends mold
macOS uses ld64, which is already fast and rarely worth swapping. Windows uses MSVC's linker, which mold does not target.
If you also have many separate test binaries, consider consolidating them under one tests/<name>.rs entry point with sub-modules. Fewer linker invocations is itself a multiplicative win on top of mold.
Design goals
- One obvious command: Fetch tools, pick the right Windows target, and run through managed zccache through the same entry point.
- Front-door builds:
soldr cargo ...is the primary build UX. - Invisible caching:
soldr cargo ...uses a soldr-managed zccache by default, withsoldr --no-cache cargo ...as the opt-out. - Real cache controls:
soldr status,soldr cache, andsoldr cleanreport and manage the soldr-managed zccache state, whilesoldr purgeremoves all Soldr-managed cache artifacts for bug clearing and benchmarking. - One cache boundary: soldr keeps its own tools, zccache session state, and managed zccache artifacts under
~/.soldr/by default. UseSOLDR_CACHE_DIRto move that root. - Disposable-worktree friendly on Windows: for build orchestration, soldr can relocate itself under
~/.soldr/runtime/soldr-self/soRUSTC_WRAPPERdoes not keep using a worktree-localsoldr.exe; stale runtime copies are cleaned up periodically. - Pre-built first: Download a pre-built binary before compiling from source. Fall back gracefully.
- Cargo-compatible: soldr preserves normal cargo arguments instead of forcing a separate workflow.
- Cross-platform: Linux, macOS, Windows (x86_64 + aarch64).
- MSVC by default on Windows: Always targets
x86_64-pc-windows-msvc(oraarch64-pc-windows-msvc) unless the active project explicitly selects another target in.cargo/config.toml,.cargo/config, orrust-toolchain.toml. MSVC links againstvcruntime140.dllwhich ships with every modern Windows install. The GNU target requires shippinglibgcc_s_seh-1.dllandlibwinpthread-1.dllwith every binary, which is extra baggage for no benefit. This matches the Rust ecosystem default: rustup, cargo-binstall, and nearly all published release binaries target MSVC. crgx gets this wrong by baking the target at compile time, causing it to look for GNU binaries when compiled under MSYS2.
Architecture
soldr/
|-- crates/
| |-- soldr-core/ # Shared types, config, cache directory layout
| |-- soldr-fetch/ # Binary resolution + download (the crgx half)
| |-- soldr-cache/ # Compilation caching (the zccache half)
| `-- soldr-cli/ # CLI entry point + wrapper mode
|-- src/soldr/ # Python package (maturin bin bindings)
`-- tests/
| Crate | Role |
|---|---|
soldr-core |
Cache paths, config, version types |
soldr-fetch |
Resolve crate binaries from crates.io metadata and GitHub Releases. Download and cache. |
soldr-cache |
zccache integration helpers, cache policy, session plumbing. |
soldr-cli |
Mode detection, cargo front door, built-in commands (status, clean, config, cache), tool fetch dispatch. |
These workspace crates are implementation details. They are not a supported public Rust library API.
Prior art
Built on lessons from:
- zccache - 2.4x faster warm builds than sccache (benchmark)
- crgx - the npx of Rust, instant tool execution
- cargo-binstall - pre-built binary resolution
- sccache - the original Rust compilation cache
Security And Verification
- SECURITY.md describes the current hardening posture and release policy.
- docs/API_BOUNDARY.md defines the supported machine-facing integration boundary.
- docs/PYPI_TRUSTED_PUBLISHING.md describes the optional Trusted Publishing path for hardened PyPI wheels.
.github/workflows/release-auto.ymlis the only release workflow: when a reviewed version bump lands onmain, it derives the version fromCargo.toml, reruns the release gate, and performs final publication through thereleaseenvironment where the release credentials live.- RELEASE.md documents the intended maximum-security release setup and owner workflow.
- docs/RELEASE_VERIFICATION.md explains how to verify published release artifacts.
- docs/TRUST_BOUNDARIES.md inventories the external systems and artifacts
soldrcurrently trusts, including the current0.5.xlimits of runtime fetched-binary trust.
License
BSD-3-Clause.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file soldr-0.7.21-py3-none-win_arm64.whl.
File metadata
- Download URL: soldr-0.7.21-py3-none-win_arm64.whl
- Upload date:
- Size: 3.1 MB
- Tags: Python 3, Windows ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
73f01e905ea5c5adf227d6c40c3c31325313a245be4192ba9a71f1783b1c9749
|
|
| MD5 |
4491c568aee097797c420e90348d6655
|
|
| BLAKE2b-256 |
3325e0d2d9a84b76139a0f67f7898faa3d82a6c56b1de34e652ea03159969d9d
|
Provenance
The following attestation bundles were made for soldr-0.7.21-py3-none-win_arm64.whl:
Publisher:
release-auto.yml on zackees/soldr
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
soldr-0.7.21-py3-none-win_arm64.whl -
Subject digest:
73f01e905ea5c5adf227d6c40c3c31325313a245be4192ba9a71f1783b1c9749 - Sigstore transparency entry: 1540337129
- Sigstore integration time:
-
Permalink:
zackees/soldr@bffe132f6db014ae3e7b1047ef3ca0fa3014f46c -
Branch / Tag:
refs/heads/main - Owner: https://github.com/zackees
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-auto.yml@bffe132f6db014ae3e7b1047ef3ca0fa3014f46c -
Trigger Event:
push
-
Statement type:
File details
Details for the file soldr-0.7.21-py3-none-win_amd64.whl.
File metadata
- Download URL: soldr-0.7.21-py3-none-win_amd64.whl
- Upload date:
- Size: 3.2 MB
- Tags: Python 3, Windows x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
308b3200c97d6a42688743fd933f8e9d68db2117e802475ea85f3c43f3af91d1
|
|
| MD5 |
02bbb83912b1ae60bdecae0576e30549
|
|
| BLAKE2b-256 |
3edaa413122f096db7fc844400980e4a6e61eade8688dcee6b3b98760f0697de
|
Provenance
The following attestation bundles were made for soldr-0.7.21-py3-none-win_amd64.whl:
Publisher:
release-auto.yml on zackees/soldr
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
soldr-0.7.21-py3-none-win_amd64.whl -
Subject digest:
308b3200c97d6a42688743fd933f8e9d68db2117e802475ea85f3c43f3af91d1 - Sigstore transparency entry: 1540337465
- Sigstore integration time:
-
Permalink:
zackees/soldr@bffe132f6db014ae3e7b1047ef3ca0fa3014f46c -
Branch / Tag:
refs/heads/main - Owner: https://github.com/zackees
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-auto.yml@bffe132f6db014ae3e7b1047ef3ca0fa3014f46c -
Trigger Event:
push
-
Statement type:
File details
Details for the file soldr-0.7.21-py3-none-manylinux_2_39_x86_64.whl.
File metadata
- Download URL: soldr-0.7.21-py3-none-manylinux_2_39_x86_64.whl
- Upload date:
- Size: 3.7 MB
- Tags: Python 3, manylinux: glibc 2.39+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
23e4aba70792ecce91f42f2a94685c0d56d6936d2ba34d73d41cdd10dd7ee0d4
|
|
| MD5 |
3bd85c7bed1404c9c6afd3be02494bb5
|
|
| BLAKE2b-256 |
360bda426abe4e08a15b7828cc7ffa7ae044ef372eb2c3e0d9a8d061b4f1c03e
|
Provenance
The following attestation bundles were made for soldr-0.7.21-py3-none-manylinux_2_39_x86_64.whl:
Publisher:
release-auto.yml on zackees/soldr
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
soldr-0.7.21-py3-none-manylinux_2_39_x86_64.whl -
Subject digest:
23e4aba70792ecce91f42f2a94685c0d56d6936d2ba34d73d41cdd10dd7ee0d4 - Sigstore transparency entry: 1540336964
- Sigstore integration time:
-
Permalink:
zackees/soldr@bffe132f6db014ae3e7b1047ef3ca0fa3014f46c -
Branch / Tag:
refs/heads/main - Owner: https://github.com/zackees
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-auto.yml@bffe132f6db014ae3e7b1047ef3ca0fa3014f46c -
Trigger Event:
push
-
Statement type:
File details
Details for the file soldr-0.7.21-py3-none-manylinux_2_39_aarch64.whl.
File metadata
- Download URL: soldr-0.7.21-py3-none-manylinux_2_39_aarch64.whl
- Upload date:
- Size: 3.6 MB
- Tags: Python 3, manylinux: glibc 2.39+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
be27b6c16a19e59ff1e609a789edc0a5ba9b668d8f64903e9bcec152b3618c4c
|
|
| MD5 |
0bc92d7ca7823c603cad93a7f04b9fd9
|
|
| BLAKE2b-256 |
0fe23798d2b89e10ae7cbb1cc456ca8cc2144bf7f2e898d3e64f5c103c8ed236
|
Provenance
The following attestation bundles were made for soldr-0.7.21-py3-none-manylinux_2_39_aarch64.whl:
Publisher:
release-auto.yml on zackees/soldr
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
soldr-0.7.21-py3-none-manylinux_2_39_aarch64.whl -
Subject digest:
be27b6c16a19e59ff1e609a789edc0a5ba9b668d8f64903e9bcec152b3618c4c - Sigstore transparency entry: 1540337336
- Sigstore integration time:
-
Permalink:
zackees/soldr@bffe132f6db014ae3e7b1047ef3ca0fa3014f46c -
Branch / Tag:
refs/heads/main - Owner: https://github.com/zackees
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-auto.yml@bffe132f6db014ae3e7b1047ef3ca0fa3014f46c -
Trigger Event:
push
-
Statement type:
File details
Details for the file soldr-0.7.21-py3-none-macosx_11_0_arm64.whl.
File metadata
- Download URL: soldr-0.7.21-py3-none-macosx_11_0_arm64.whl
- Upload date:
- Size: 3.3 MB
- Tags: Python 3, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3bb90867f6080acdfce6d1029946931a84e402a7b83a12f89c38f0acdcdef776
|
|
| MD5 |
f9d79cfc84ed5130a2f936bf48e53572
|
|
| BLAKE2b-256 |
f4bff307b1e59dd37874e17be6256d140f5be0d40c46df1b7b23e5e539bc9ddc
|
Provenance
The following attestation bundles were made for soldr-0.7.21-py3-none-macosx_11_0_arm64.whl:
Publisher:
release-auto.yml on zackees/soldr
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
soldr-0.7.21-py3-none-macosx_11_0_arm64.whl -
Subject digest:
3bb90867f6080acdfce6d1029946931a84e402a7b83a12f89c38f0acdcdef776 - Sigstore transparency entry: 1540336831
- Sigstore integration time:
-
Permalink:
zackees/soldr@bffe132f6db014ae3e7b1047ef3ca0fa3014f46c -
Branch / Tag:
refs/heads/main - Owner: https://github.com/zackees
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-auto.yml@bffe132f6db014ae3e7b1047ef3ca0fa3014f46c -
Trigger Event:
push
-
Statement type:
File details
Details for the file soldr-0.7.21-py3-none-macosx_10_12_x86_64.whl.
File metadata
- Download URL: soldr-0.7.21-py3-none-macosx_10_12_x86_64.whl
- Upload date:
- Size: 3.5 MB
- Tags: Python 3, macOS 10.12+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
122d69c7023df34af583c9d1e27042dfb31f34d637ebe3d8c3ceb1d01a6613c9
|
|
| MD5 |
392ef3876ebcc7b7eacb7230a07c541a
|
|
| BLAKE2b-256 |
862ebb7183b5be84edb22610fb30af7e874e4c8e85d539e35acfb728ba3b1aaf
|
Provenance
The following attestation bundles were made for soldr-0.7.21-py3-none-macosx_10_12_x86_64.whl:
Publisher:
release-auto.yml on zackees/soldr
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
soldr-0.7.21-py3-none-macosx_10_12_x86_64.whl -
Subject digest:
122d69c7023df34af583c9d1e27042dfb31f34d637ebe3d8c3ceb1d01a6613c9 - Sigstore transparency entry: 1540336709
- Sigstore integration time:
-
Permalink:
zackees/soldr@bffe132f6db014ae3e7b1047ef3ca0fa3014f46c -
Branch / Tag:
refs/heads/main - Owner: https://github.com/zackees
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-auto.yml@bffe132f6db014ae3e7b1047ef3ca0fa3014f46c -
Trigger Event:
push
-
Statement type: