🍺 BREW Explorer

← all formulae

cargo-chef

brew install cargo-chef v0.1.77 Apache-2.0 OR MIT

Cargo subcommand to speed up Rust Docker builds using Docker layer caching

20
30-day installs · #6747
47
90-day · #7495
262
365-day · #6666
2.6k
★ GitHub stars · updated 4mo ago

Build dependencies

GitHub topics

cargo ci docker rust

Links

Raw metadata
{
  "aliases": [],
  "alternatives": [],
  "build_dependencies": [
    "rust"
  ],
  "categories": [],
  "caveats": null,
  "conflicts_with": [],
  "dependencies": [],
  "deprecated": 0,
  "deprecation_reason": null,
  "desc": "Cargo subcommand to speed up Rust Docker builds using Docker layer caching",
  "disable_reason": null,
  "disabled": 0,
  "enrichment_fetched_at": "2026-06-20T23:36:08+00:00",
  "first_seen": "2026-06-20T23:34:18+00:00",
  "full_name": "cargo-chef",
  "github_default_branch": "main",
  "github_last_commit_at": "2026-04-13T08:31:56Z",
  "github_readme_excerpt": "\u003ch1 align=\"center\"\u003ecargo-chef\u003c/h1\u003e\n\u003cdiv align=\"center\"\u003e\n \u003cstrong\u003e\n   Cache the dependencies of your Rust project and speed up your Docker builds.\n \u003c/strong\u003e\n\u003c/div\u003e\n\n\u003cbr /\u003e\n\n\u003cdiv align=\"center\"\u003e\n  \u003c!-- Crates version --\u003e\n  \u003ca href=\"https://crates.io/crates/cargo-chef\"\u003e\n    \u003cimg src=\"https://img.shields.io/crates/v/cargo-chef.svg?style=flat-square\"\n    alt=\"Crates.io version\" /\u003e\n  \u003c/a\u003e\n  \u003c!-- Downloads --\u003e\n  \u003ca href=\"https://crates.io/crates/cargo-chef\"\u003e\n    \u003cimg src=\"https://img.shields.io/crates/d/cargo-chef.svg?style=flat-square\"\n      alt=\"Download\" /\u003e\n  \u003c/a\u003e\n\u003c/div\u003e\n\u003cbr/\u003e\n\n\u003e `cargo-chef` was initially developed for the deployment chapter of [Zero to Production In Rust](https://zero2prod.com), a hands-on introduction to backend development using the Rust programming language.\n\n# Table of Contents\n0. [How to install](#how-to-install)\n1. [How to use](#how-to-use)\n2. [Benefits vs Limitations](#benefits-vs-limitations)\n3. [License](#license)\n\n## How To Install \n\nYou can install `cargo-chef` from [crates.io](https://crates.io) with\n\n```bash\ncargo install cargo-chef --locked\n```\n\n## How to use\n\n\u003e :warning:  **cargo-chef is not meant to be run locally**  \n\u003e Its primary use-case is to speed up container builds by running BEFORE\n\u003e the actual source code is copied over. Don\u0027t run it on existing codebases to avoid\n\u003e having files being overwritten.\n\n`cargo-chef` exposes two commands: `prepare` and `cook`:\n\n```bash\ncargo chef --help\n```\n\n```text\n\ncargo-chef\n\nUSAGE:\n    cargo chef \u003cSUBCOMMAND\u003e\n\nSUBCOMMANDS:\n    cook       Re-hydrate the minimum project skeleton identified by `cargo chef prepare` and\n               build it to cache dependencies\n    prepare    Analyze the current project to determine the minimum subset of files (Cargo.lock\n               and Cargo.toml manifests) required to build it and cache dependencies\n```\n\n`prepare` examines your project and builds a _recipe_ that captures the set of information required to build your dependencies.\n\n```bash\ncargo chef prepar",
  "github_repo": "LukeMathWalker/cargo-chef",
  "github_stars": 2634,
  "github_topics": [
    "cargo",
    "ci",
    "docker",
    "rust"
  ],
  "homepage": "https://github.com/LukeMathWalker/cargo-chef",
  "homepage_og_description": null,
  "homepage_og_image": null,
  "homepage_title": null,
  "installs_30d": 20,
  "installs_365d": 262,
  "installs_90d": 47,
  "keg_only": 0,
  "keg_only_reason": null,
  "last_seen": "2026-06-20T23:34:18+00:00",
  "license": "Apache-2.0 OR MIT",
  "llm_generated_at": null,
  "llm_model": null,
  "name": "cargo-chef",
  "oldnames": [],
  "one_liner": null,
  "optional_dependencies": [],
  "rank_30d": 6747,
  "rank_365d": 6666,
  "rank_90d": 7495,
  "raw_hash": "44cc01d4c82fcac9",
  "recommended_dependencies": [],
  "revision": 0,
  "ruby_source_path": "Formula/c/cargo-chef.rb",
  "tap": "homebrew/core",
  "test_dependencies": [
    "rustup"
  ],
  "uses_from_macos": [],
  "version_head": null,
  "version_stable": "0.1.77",
  "versioned_formulae": [],
  "why_use_this": null
}