Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please support specifying --features for only some of the crates #46

Open
kdy1 opened this issue Jul 15, 2024 · 1 comment
Open

Please support specifying --features for only some of the crates #46

kdy1 opened this issue Jul 15, 2024 · 1 comment

Comments

@kdy1
Copy link

kdy1 commented Jul 15, 2024

Hi! Thank you for creating a wonderful tool!

I'm using codspeed for the swc project and I want to enable scoped of swc_allocator while benchmarking. But it seems like cargo codspeed build passes the --features flag to all invocations of cargo build.

I think it should be supported.

@art049
Copy link
Member

art049 commented Sep 5, 2024

Hello @kdy1, yes, we want to support that. We plan on refactoring cargo-codspeed to use the cargo CLI under the hood instead of the cargo API (#50). This kind of configuration will be available out of the box when this is done.

Meanwhile, you can build packages individually with the feature flag (since we support the -p flag already).
Building would look like this:

cargo codspeed build -p my_package --features my_feature
cargo codspeed build -p another_package

And then just cargo codspeed run will run all the built benchmarks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants