-
-
Notifications
You must be signed in to change notification settings - Fork 3
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
Added support the [cargo-new]
table
#21
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
src/de.rs
Outdated
pub vcs: Option<Value<VersionControlSoftware>>, | ||
} | ||
|
||
#[allow(clippy::exhaustive_enums)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this enum should use #[non_exhaustive]
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, good catch. I made this #[non_exhaustive]
and reexported it at the crate root to match the other enums 👍
tests/test.rs
Outdated
@@ -72,7 +72,7 @@ fn assert_reference_example(de: fn(&Path, ResolveOptions) -> Result<Config>) -> | |||
assert_eq!(config.future_incompat_report.frequency, Some(Frequency::Always)); | |||
|
|||
// TODO | |||
// [cargo-new] | |||
assert_eq!(config.cargo_new.vcs, None); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can test this by uncommenting the following two lines:
cargo-config2/tests/fixtures/reference/.cargo/config.toml
Lines 41 to 42 in bb273c0
# [cargo-new] | |
# vcs = "none" # VCS to use ('git', 'hg', 'pijul', 'fossil', 'none') |
Published in 0.1.28. |
Hey there! 👋
I also added support for the
cargo-new
table which only has 1 none deprecated property.I did not add the deprecated fields.