Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Install

Two binaries: fast_code_search_server (the index and its APIs) and fcs (the command-line client). They are built together and released together.

Release archive

Download the archive for your platform from the latest release, verify it, unpack it, and put both binaries on your PATH:

sha256sum -c fast_code_search-v*-x86_64-unknown-linux-musl.tar.gz.sha256
tar -xzf fast_code_search-v*-x86_64-unknown-linux-musl.tar.gz
mkdir -p ~/.local/bin && cp fast_code_search_server fcs ~/.local/bin/
PlatformArchive
Linux x86_64, static (recommended)…-x86_64-unknown-linux-musl.tar.gz (any distribution, no glibc dependency)
Linux x86_64, glibc…-x86_64-unknown-linux-gnu.tar.gz (needs glibc 2.39 or later, see below)
macOS, Apple silicon…-aarch64-apple-darwin.tar.gz
macOS, Intel…-x86_64-apple-darwin.tar.gz
Windows x86_64…-x86_64-pc-windows-msvc.zip

Each archive also contains config.toml.example, the startup unit files under deploy/, and the CLI and startup guides. On macOS, a downloaded binary may need xattr -d com.apple.quarantine <file> before it runs.

Which Linux download?

Use x86_64-unknown-linux-musl unless you know your glibc is new enough for the gnu archive. The musl archive is statically linked: it has no glibc dependency and runs on any x86_64 Linux, old or new, including Alpine and containers.

The gnu archive links against the system glibc and needs one at least as new as the release runner’s. For v0.22.0 that is glibc 2.39 (the binaries use pidfd_spawnp and pidfd_getpid, added in 2.39):

Works (glibc 2.39+)Does not (older glibc)
Ubuntu 24.04 and later, Debian 13, Fedora 40 and later, RHEL / Rocky / Alma 10Ubuntu 22.04 (2.35), Debian 12 (2.36), RHEL / Rocky / Alma 9 (2.34), Amazon Linux 2023 (2.34)

Check yours with ldd --version. On an older glibc the gnu binaries stop at once with an error like fcs: /lib/x86_64-linux-gnu/libc.so.6: version 'GLIBC_2.39' not found; take the musl archive instead. Releases are built on GitHub’s ubuntu-latest image, so the minimum can rise in a later release; the release page states it for each release.

Both archives use the same allocator (mimalloc, see Memory), so musl’s own slower allocator does not apply. No Linux arm64 archive or container image is published; on arm64, build with cargo install.

Verifying a download

Every archive ships with a .sha256 file and, for releases after v0.13.0, a Sigstore bundle (.sigstore.json) produced by the release workflow’s own identity. The checksum proves the file is intact; the signature proves it was built by this repository’s release workflow for this tag, and not merely uploaded by someone holding the account.

sha256sum -c fast_code_search-v0.23.0-x86_64-unknown-linux-musl.tar.gz.sha256
cosign verify-blob \
  --bundle fast_code_search-v0.23.0-x86_64-unknown-linux-musl.tar.gz.sigstore.json \
  --certificate-identity-regexp '^https://github.com/jburrow/fast_code_search/' \
  --certificate-oidc-issuer https://token.actions.githubusercontent.com \
  fast_code_search-v0.23.0-x86_64-unknown-linux-musl.tar.gz

cosign is a single binary; no key management is involved because the signing is keyless.

With cargo

cargo binstall downloads the release archive for your platform instead of compiling, using the metadata in Cargo.toml. Until the crate is on crates.io, point it at the repository:

cargo binstall --git https://github.com/jburrow/fast_code_search fast_code_search

Once fast_code_search is published on crates.io, cargo binstall fast_code_search and cargo install fast_code_search work without the --git flag.

Homebrew

A tap is wired into the release workflow and will be announced here once its repository exists; until then use the archive, cargo binstall or the container image.

Container image

Every release from v0.13.0 is also published as ghcr.io/jburrow/fast_code_search (tags latest, 0.23, 0.23.0). The image indexes whatever is mounted at /src, watches it for changes, and serves the web UI and REST API on port 8080 and gRPC on 50051 (add --single-port to the command, or single_port = true in its config, to serve gRPC on 8080 as well):

docker run --rm -p 8080:8080 -v "$PWD:/src:ro" ghcr.io/jburrow/fast_code_search

To keep the index between runs mount a volume at /var/lib/fast_code_search; to change any setting mount your own file at /etc/fast_code_search/config.toml (the baked-in one is deploy/docker/config.toml). The fcs client is in the image too: docker exec <container> fcs 'fn main'.

From source

Requires Rust 1.91 or newer and the Protocol Buffers compiler (protoc, from your package manager or the releases page).

cargo install --git https://github.com/jburrow/fast_code_search --bins

or, from a checkout, cargo build --release and take target/release/fast_code_search_server and target/release/fcs.

Check

fast_code_search_server --version
fcs --version

Next: First index, first search.