Installation¶
Scratchsmith is Linux only (amd64/arm64). It stages a Linux glibc rootfs, so it does not run on macOS or native Windows. Use a Linux container or WSL2 there.
One-line install¶
Downloads the signed release binary, verifies it against the cosign-signed checksums.txt, and
installs it to ~/.local/bin (or /usr/local/bin as root):
Piping to bash runs install.sh.
You can read it first. VERSION and BIN_DIR env vars override the tag and install
directory. Uninstall with --uninstall:
curl -fsSL https://raw.githubusercontent.com/schubydoo/scratchsmith/main/install.sh | bash -s -- --uninstall
Homebrew¶
Cargo¶
Build and install from source with Cargo (Rust 1.96+):
Release binary¶
Download a release binary, Linux amd64 or arm64, from the latest release. Verify the signature and provenance first (see Verifying releases):
tar -xzf scratchsmith-*-linux-amd64.tar.gz # or -linux-arm64
./scratchsmith-*/scratchsmith --version
Container image¶
Pull the signed image:
:latest is a minimal FROM scratch image. It runs every subcommand that needs no external
tool and no certificate store. It does not run pack, because a scratch image carries none
of the tools pack needs, and it does not run index. To run pack inside a container, pull
the :toolbox image instead (Wolfi base + the full toolchain). The
toolbox section in Usage lists which subcommands run where.
Build from source¶
Rust 1.96+:
git clone https://github.com/schubydoo/scratchsmith
cd scratchsmith
cargo build --release
# binary at target/release/scratchsmith
Run scratchsmith doctor to see which optional external tools (syft, strip, tini, …) are present.
Shell completions¶
Generate a script for your shell and drop it where the shell looks: