LukeMathWalker / LukeMathWalker/cargo-chef

Support multiple `--bin` values in `cargo chef prepare`

Open
#284 1 comment 10 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
2.7k
Forks
146
PR merge metrics
No merged PRs in 30d

Description

Hello!

I'm working on a workspace project where

  1. some projects are apps which are meant to be bundled in docker images
  2. some projects are libraries which are used by those apps
  3. some projects are separate (e.g. a demo application) and shouldn't be involved in the docker build at all.

I'd really like to be able to build a recipe file which included all projects of types 1 and 2, but excluded 3.
It looks like the prepare command accepts a --bin argument which would help with this, but you can only use that for a single project. I think it would serve my needs if you could pass more than one --bin, like you can with the build command.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by inspecting the cargo chef prepare command's handling of --bin and compare it with how the build command accepts multiple values. Confirm how selected binaries determine workspace projects in the recipe, then verify that multiple --bin values include the requested applications and libraries while excluding unrelated projects.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, rust
Domain
build-system, cli
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.