Commit Graph

11 Commits

Author SHA1 Message Date
Ivan Petkov
35bc915249
cleanCargoToml: also clean variants using underscores (#626) 2024-05-26 17:41:17 +00:00
Ivan Petkov
c7bb4ed1f3
cleanCargoToml: strip out [lints] definitions when cleaning (#516) 2024-02-08 03:34:33 +00:00
Antti Keränen
99de890b6e
Keep "resolver" when cleaning Cargo.toml (#327)
For projects using version != 2021 and resolver = 2, the resolver
information needs to be kept or otherwise the dependency build might
fail.

---------

Co-authored-by: Ivan Petkov <ivanppetkov@gmail.com>
2023-05-18 21:03:02 -07:00
Ivan Petkov
6b864957e1
checks: add tests for building crates using workspace inheritance (#147) 2022-10-23 22:56:18 +00:00
adisbladis
a1e56fba69 Stop passing around fromTOML
It's a builtin that we can just use directly.
2022-06-03 02:01:02 +08:00
Ivan Petkov
b4a1445590
cleanCargoToml: retain crate-type
* Some tools may try to inspect crate types (e.g. wasm-pack) so it may
  be useful to retain the attribute
* In general, the crate-type can influence the project's "structure" so
  we should remain faithful to that
2021-12-31 18:40:01 -08:00
Ivan Petkov
e6cdd3df92
cleanCargoToml: strip required-features from target definitions
* Turns out the `required-features` attribute is only used from hiding
  targets from cargo's selection (e.g. do not build unless feature is
  enabled) and does not actually influence what features cargo will
  enable/build for dependencies
2021-12-31 18:34:06 -08:00
Ivan Petkov
4a515f43ca
cleanCargoToml: do not replace path attributes
* Keep the paths as specified in the Cargo.toml while cleaning, leaving
  it up to the caller to replace them if necessary
2021-12-30 10:04:12 -08:00
Ivan Petkov
234257c239
cleanCargoToml: do not strip edition fields
* The edition entries can affect cargo behavior, not just rustc
  behavior, so we should keep them in for consistency with what the
  project expects
2021-12-30 09:44:50 -08:00
Ivan Petkov
cf1c6eb0e8
Add checks for cleanCargoToml 2021-12-29 19:26:55 -08:00
Ivan Petkov
a286fe1ff5
Add cleanCargoToml 2021-12-29 16:03:39 -08:00