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

cargo fix: Print targets/features/cfg that will be fixed #5740

Closed
killercup opened this Issue Jul 17, 2018 · 8 comments

Comments

Projects
None yet
4 participants
@killercup
Copy link
Member

killercup commented Jul 17, 2018

With #5739, cargo fix learnt to check all targets by default. Since this might be a source of confusion, it would be helpful to also print out which targets we are fixing.

Running cargo fix should print out a line like this (right at the start):

Collecting suggestions for these targets: library, foo (binary), and bar (example). No optional features enabled. No specific cfg flags given.

@killercup

This comment has been minimized.

Copy link
Member Author

killercup commented Aug 14, 2018

This might require changing/dealing with some cargo internals. There is this method:

fn generate_targets<'a>(
ws: &Workspace,
profiles: &Profiles,
packages: &[&'a Package],
filter: &CompileFilter,
default_arch_kind: Kind,
resolve: &Resolve,
build_config: &BuildConfig,
) -> CargoResult<Vec<Unit<'a>>> {

as part of ops::compile, but it's not directly accessible in cargo-fix' entry function (here).

@JoshBrudnak

This comment has been minimized.

Copy link

JoshBrudnak commented Aug 19, 2018

@killercup I would like to help out with this. Thanks.

@killercup

This comment has been minimized.

Copy link
Member Author

killercup commented Aug 21, 2018

@JoshBrudnak this is assigned to me to remind me to check in on this. How's it going? :)

@JoshBrudnak

This comment has been minimized.

Copy link

JoshBrudnak commented Aug 21, 2018

I haven't had much time to work on it, but I'll be able to look into it later today. Thanks. 👍

@JoshBrudnak

This comment has been minimized.

Copy link

JoshBrudnak commented Aug 29, 2018

I guess I won't be working on this since @dwijnand took it. 😄

@dwijnand

This comment has been minimized.

Copy link
Member

dwijnand commented Aug 30, 2018

There's an initial, starting implementation in #5947, but @alexcrichton is hoping to get a few more user reports to figure out what needs printing. See his comment.

@dwijnand

This comment has been minimized.

Copy link
Member

dwijnand commented Oct 3, 2018

Move to close?

@alexcrichton

This comment has been minimized.

Copy link
Member

alexcrichton commented Oct 3, 2018

Agreed yeah, we can always reopen if necessary!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.