874 Commits

Author SHA1 Message Date
Eric Huss
3948fa5e15 Update all dependencies 2025-02-09 15:50:36 -08:00
Weihang Lo
fcb79a5c45
Update curl from 8.9.0 to 8.12.0 (#15162)
Quite a lot of changes between these releases:

Release notes: https://curl.se/ch/8.12.0.html
Release notes: https://curl.se/ch/8.11.1.html
Release notes: https://curl.se/ch/8.11.0.html
Release notes: https://curl.se/ch/8.10.1.html
Release notes: https://curl.se/ch/8.10.0.html
Blog: https://daniel.haxx.se/blog/2025/02/05/curl-8-12-0/
Blog: https://daniel.haxx.se/blog/2024/12/11/curl-8-11-1/
Blog: https://daniel.haxx.se/blog/2024/11/06/curl-8-11-0/
Blog: https://daniel.haxx.se/blog/2024/09/18/curl-8-10-1/
Blog: https://daniel.haxx.se/blog/2024/09/11/curl-8-10-0/
2025-02-09 22:42:00 +00:00
Weihang Lo
d64e7a462d
Update annotate-snippets from 0.11.4 to 0.11.5 (#15165)
Changelog:
https://github.com/rust-lang/annotate-snippets-rs/blob/master/CHANGELOG.md#0115---2024-12-09

Looks to have some minor rendering differences.
2025-02-09 21:36:06 +00:00
Eric Huss
b5394da406 Update annotate-snippets from 0.11.4 to 0.11.5
Changelog: https://github.com/rust-lang/annotate-snippets-rs/blob/master/CHANGELOG.md#0115---2024-12-09

Looks to have some minor rendering differences.
2025-02-09 12:46:36 -08:00
Eric Huss
0d2ddc9942 Update rusqlite from 0.32.1 to 0.33.0
Changes: https://github.com/rusqlite/rusqlite/releases/tag/v0.33.0
2025-02-09 12:06:21 -08:00
Eric Huss
84eabfa746 Update curl from 8.9.0 to 8.12.0 2025-02-09 11:48:06 -08:00
Ed Page
6d1f6be115
chore(deps): update rust crate rand to 0.9.0 (#15129)
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [rand](https://rust-random.github.io/book)
([source](https://redirect.github.com/rust-random/rand)) |
workspace.dependencies | minor | `0.8.5` -> `0.9.0` |

---

### Release Notes

<details>
<summary>rust-random/rand (rand)</summary>

###
[`v0.9.0`](https://redirect.github.com/rust-random/rand/blob/HEAD/CHANGELOG.md#090---2025-01-27)

[Compare
Source](https://redirect.github.com/rust-random/rand/compare/0.8.5...0.9.0)

##### Security and unsafe

- Policy: "rand is not a crypto library"
([#&#8203;1514](https://redirect.github.com/rust-random/rand/issues/1514))
- Remove fork-protection from `ReseedingRng` and `ThreadRng`. Instead,
it is recommended to call `ThreadRng::reseed` on fork.
([#&#8203;1379](https://redirect.github.com/rust-random/rand/issues/1379))
- Use `zerocopy` to replace some `unsafe` code
([#&#8203;1349](https://redirect.github.com/rust-random/rand/issues/1349),
[#&#8203;1393](https://redirect.github.com/rust-random/rand/issues/1393),
[#&#8203;1446](https://redirect.github.com/rust-random/rand/issues/1446),
[#&#8203;1502](https://redirect.github.com/rust-random/rand/issues/1502))

##### Dependencies

- Bump the MSRV to 1.63.0
([#&#8203;1207](https://redirect.github.com/rust-random/rand/issues/1207),
[#&#8203;1246](https://redirect.github.com/rust-random/rand/issues/1246),
[#&#8203;1269](https://redirect.github.com/rust-random/rand/issues/1269),
[#&#8203;1341](https://redirect.github.com/rust-random/rand/issues/1341),
[#&#8203;1416](https://redirect.github.com/rust-random/rand/issues/1416),
[#&#8203;1536](https://redirect.github.com/rust-random/rand/issues/1536));
note that 1.60.0 may work for dependents when using
`--ignore-rust-version`
- Update to `rand_core` v0.9.0
([#&#8203;1558](https://redirect.github.com/rust-random/rand/issues/1558))

##### Features

- Support `std` feature without `getrandom` or `rand_chacha`
([#&#8203;1354](https://redirect.github.com/rust-random/rand/issues/1354))
- Enable feature `small_rng` by default
([#&#8203;1455](https://redirect.github.com/rust-random/rand/issues/1455))
- Remove implicit feature `rand_chacha`; use `std_rng` instead.
([#&#8203;1473](https://redirect.github.com/rust-random/rand/issues/1473))
- Rename feature `serde1` to `serde`
([#&#8203;1477](https://redirect.github.com/rust-random/rand/issues/1477))
- Rename feature `getrandom` to `os_rng`
([#&#8203;1537](https://redirect.github.com/rust-random/rand/issues/1537))
- Add feature `thread_rng`
([#&#8203;1547](https://redirect.github.com/rust-random/rand/issues/1547))

##### API changes: rand_core traits

- Add fn `RngCore::read_adapter` implementing `std::io::Read`
([#&#8203;1267](https://redirect.github.com/rust-random/rand/issues/1267))
- Add trait `CryptoBlockRng: BlockRngCore`; make `trait CryptoRng:
RngCore`
([#&#8203;1273](https://redirect.github.com/rust-random/rand/issues/1273))
- Add traits `TryRngCore`, `TryCryptoRng`
([#&#8203;1424](https://redirect.github.com/rust-random/rand/issues/1424),
[#&#8203;1499](https://redirect.github.com/rust-random/rand/issues/1499))
- Rename `fn SeedableRng::from_rng` -> `try_from_rng` and add infallible
variant `fn from_rng`
([#&#8203;1424](https://redirect.github.com/rust-random/rand/issues/1424))
- Rename `fn SeedableRng::from_entropy` -> `from_os_rng` and add
fallible variant `fn try_from_os_rng`
([#&#8203;1424](https://redirect.github.com/rust-random/rand/issues/1424))
- Add bounds `Clone` and `AsRef` to associated type `SeedableRng::Seed`
([#&#8203;1491](https://redirect.github.com/rust-random/rand/issues/1491))

##### API changes: Rng trait and top-level fns

- Rename fn `rand::thread_rng()` to `rand::rng()` and remove from the
prelude
([#&#8203;1506](https://redirect.github.com/rust-random/rand/issues/1506))
- Remove fn `rand::random()` from the prelude
([#&#8203;1506](https://redirect.github.com/rust-random/rand/issues/1506))
- Add top-level fns `random_iter`, `random_range`, `random_bool`,
`random_ratio`, `fill`
([#&#8203;1488](https://redirect.github.com/rust-random/rand/issues/1488))
- Re-introduce fn `Rng::gen_iter` as `random_iter`
([#&#8203;1305](https://redirect.github.com/rust-random/rand/issues/1305),
[#&#8203;1500](https://redirect.github.com/rust-random/rand/issues/1500))
- Rename fn `Rng::gen` to `random` to avoid conflict with the new `gen`
keyword in Rust 2024
([#&#8203;1438](https://redirect.github.com/rust-random/rand/issues/1438))
- Rename fns `Rng::gen_range` to `random_range`, `gen_bool` to
`random_bool`, `gen_ratio` to `random_ratio`
([#&#8203;1505](https://redirect.github.com/rust-random/rand/issues/1505))
- Annotate panicking methods with `#[track_caller]`
([#&#8203;1442](https://redirect.github.com/rust-random/rand/issues/1442),
[#&#8203;1447](https://redirect.github.com/rust-random/rand/issues/1447))

##### API changes: RNGs

- Fix `<SmallRng as SeedableRng>::Seed` size to 256 bits
([#&#8203;1455](https://redirect.github.com/rust-random/rand/issues/1455))
- Remove first parameter (`rng`) of `ReseedingRng::new`
([#&#8203;1533](https://redirect.github.com/rust-random/rand/issues/1533))

##### API changes: Sequences

- Split trait `SliceRandom` into `IndexedRandom`, `IndexedMutRandom`,
`SliceRandom`
([#&#8203;1382](https://redirect.github.com/rust-random/rand/issues/1382))
- Add `IndexedRandom::choose_multiple_array`, `index::sample_array`
([#&#8203;1453](https://redirect.github.com/rust-random/rand/issues/1453),
[#&#8203;1469](https://redirect.github.com/rust-random/rand/issues/1469))

##### API changes: Distributions: renames

- Rename module `rand::distributions` to `rand::distr`
([#&#8203;1470](https://redirect.github.com/rust-random/rand/issues/1470))
- Rename distribution `Standard` to `StandardUniform`
([#&#8203;1526](https://redirect.github.com/rust-random/rand/issues/1526))
- Move `distr::Slice` -> `distr::slice::Choose`, `distr::EmptySlice` ->
`distr::slice::Empty`
([#&#8203;1548](https://redirect.github.com/rust-random/rand/issues/1548))
- Rename trait `distr::DistString` -> `distr::SampleString`
([#&#8203;1548](https://redirect.github.com/rust-random/rand/issues/1548))
- Rename `distr::DistIter` -> `distr::Iter`, `distr::DistMap` ->
`distr::Map`
([#&#8203;1548](https://redirect.github.com/rust-random/rand/issues/1548))

##### API changes: Distributions

- Relax `Sized` bound on `Distribution<T> for &D`
([#&#8203;1278](https://redirect.github.com/rust-random/rand/issues/1278))
- Remove impl of `Distribution<Option<T>>` for `StandardUniform`
([#&#8203;1526](https://redirect.github.com/rust-random/rand/issues/1526))
- Let distribution `StandardUniform` support all `NonZero*` types
([#&#8203;1332](https://redirect.github.com/rust-random/rand/issues/1332))
- Fns `{Uniform, UniformSampler}::{new, new_inclusive}` return a
`Result` (instead of potentially panicking)
([#&#8203;1229](https://redirect.github.com/rust-random/rand/issues/1229))
- Distribution `Uniform` implements `TryFrom` instead of `From` for
ranges
([#&#8203;1229](https://redirect.github.com/rust-random/rand/issues/1229))
- Add `UniformUsize`
([#&#8203;1487](https://redirect.github.com/rust-random/rand/issues/1487))
- Remove support for generating `isize` and `usize` values with
`StandardUniform`, `Uniform` (except via `UniformUsize`) and `Fill` and
usage as a `WeightedAliasIndex` weight
([#&#8203;1487](https://redirect.github.com/rust-random/rand/issues/1487))
- Add impl `DistString` for distributions `Slice<char>` and
`Uniform<char>`
([#&#8203;1315](https://redirect.github.com/rust-random/rand/issues/1315))
- Add fn `Slice::num_choices`
([#&#8203;1402](https://redirect.github.com/rust-random/rand/issues/1402))
- Add fn `p()` for distribution `Bernoulli` to access probability
([#&#8203;1481](https://redirect.github.com/rust-random/rand/issues/1481))

##### API changes: Weighted distributions

- Add `pub` module `rand::distr::weighted`, moving `WeightedIndex` there
([#&#8203;1548](https://redirect.github.com/rust-random/rand/issues/1548))
- Add trait `weighted::Weight`, allowing `WeightedIndex` to trap
overflow
([#&#8203;1353](https://redirect.github.com/rust-random/rand/issues/1353))
- Add fns `weight, weights, total_weight` to distribution
`WeightedIndex`
([#&#8203;1420](https://redirect.github.com/rust-random/rand/issues/1420))
- Rename enum `WeightedError` to `weighted::Error`, revising variants
([#&#8203;1382](https://redirect.github.com/rust-random/rand/issues/1382))
and mark as `#[non_exhaustive]`
([#&#8203;1480](https://redirect.github.com/rust-random/rand/issues/1480))

##### API changes: SIMD

- Switch to `std::simd`, expand SIMD & docs
([#&#8203;1239](https://redirect.github.com/rust-random/rand/issues/1239))

##### Reproducibility-breaking changes

- Make `ReseedingRng::reseed` discard remaining data from the last block
generated
([#&#8203;1379](https://redirect.github.com/rust-random/rand/issues/1379))
- Change fn `SmallRng::seed_from_u64` implementation
([#&#8203;1203](https://redirect.github.com/rust-random/rand/issues/1203))
- Allow `UniformFloat::new` samples and `UniformFloat::sample_single` to
yield `high`
([#&#8203;1462](https://redirect.github.com/rust-random/rand/issues/1462))
- Fix portability of distribution `Slice`
([#&#8203;1469](https://redirect.github.com/rust-random/rand/issues/1469))
- Make `Uniform` for `usize` portable via `UniformUsize`
([#&#8203;1487](https://redirect.github.com/rust-random/rand/issues/1487))
- Fix `IndexdRandom::choose_multiple_weighted` for very small seeds and
optimize for large input length / low memory
([#&#8203;1530](https://redirect.github.com/rust-random/rand/issues/1530))

##### Reproducibility-breaking optimisations

- Optimize fn `sample_floyd`, affecting output of
`rand::seq::index::sample` and `rand::seq::SliceRandom::choose_multiple`
([#&#8203;1277](https://redirect.github.com/rust-random/rand/issues/1277))
- New, faster algorithms for `IteratorRandom::choose` and
`choose_stable`
([#&#8203;1268](https://redirect.github.com/rust-random/rand/issues/1268))
- New, faster algorithms for `SliceRandom::shuffle` and
`partial_shuffle`
([#&#8203;1272](https://redirect.github.com/rust-random/rand/issues/1272))
- Optimize distribution `Uniform`: use Canon's method (single sampling)
/ Lemire's method (distribution sampling) for faster sampling (breaks
value stability;
[#&#8203;1287](https://redirect.github.com/rust-random/rand/issues/1287))
- Optimize fn `sample_single_inclusive` for floats (+~20% perf)
([#&#8203;1289](https://redirect.github.com/rust-random/rand/issues/1289))

##### Other optimisations

- Improve `SmallRng` initialization performance
([#&#8203;1482](https://redirect.github.com/rust-random/rand/issues/1482))
- Optimise SIMD widening multiply
([#&#8203;1247](https://redirect.github.com/rust-random/rand/issues/1247))

##### Other

- Add `Cargo.lock.msrv` file
([#&#8203;1275](https://redirect.github.com/rust-random/rand/issues/1275))
- Reformat with `rustfmt` and enforce
([#&#8203;1448](https://redirect.github.com/rust-random/rand/issues/1448))
- Apply Clippy suggestions and enforce
([#&#8203;1448](https://redirect.github.com/rust-random/rand/issues/1448),
[#&#8203;1474](https://redirect.github.com/rust-random/rand/issues/1474))
- Move all benchmarks to new `benches` crate
([#&#8203;1329](https://redirect.github.com/rust-random/rand/issues/1329),
[#&#8203;1439](https://redirect.github.com/rust-random/rand/issues/1439))
and migrate to Criterion
([#&#8203;1490](https://redirect.github.com/rust-random/rand/issues/1490))

##### Documentation

- Improve `ThreadRng` related docs
([#&#8203;1257](https://redirect.github.com/rust-random/rand/issues/1257))
- Docs: enable experimental `--generate-link-to-definition` feature
([#&#8203;1327](https://redirect.github.com/rust-random/rand/issues/1327))
- Better doc of crate features, use `doc_auto_cfg`
([#&#8203;1411](https://redirect.github.com/rust-random/rand/issues/1411),
[#&#8203;1450](https://redirect.github.com/rust-random/rand/issues/1450))

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "before 5am on the first day of the
month" (UTC), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/rust-lang/cargo).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4xNDUuMCIsInVwZGF0ZWRJblZlciI6IjM5LjE0NS4wIiwidGFyZ2V0QnJhbmNoIjoibWFzdGVyIiwibGFiZWxzIjpbXX0=-->
2025-02-03 22:19:09 +00:00
renovate[bot]
e9132fb248 chore(deps): update rust crate rand to 0.9.0 2025-02-01 00:25:29 +00:00
renovate[bot]
4f60d690bc
chore(deps): update rust crate gix to 0.70.0 2025-02-01 00:25:03 +00:00
Ed Page
7ab469d339 chore: Update clap_complete 2025-01-29 09:43:25 -06:00
renovate[bot]
38105c381d
chore(deps): update msrv (3 versions) to v1.82 2025-01-10 20:40:54 +00:00
Ed Page
b75783a923 chore: Bump versions 2025-01-09 15:18:56 -06:00
renovate[bot]
7ee43a58ec
chore(deps): update msrv (1 version) to v1.84 2025-01-09 19:15:56 +00:00
Weihang Lo
a4c0d39826
fix: emit warnings as warnings when learning rust target info (#15036)
### What does this PR try to resolve?

This is a horrible hack,
which lets the rustc invocation for learning target info always emit
warnings as warnings.
But at least it unblocks people who pass `-Awarnings` via RUSTFLAGS.

A long-term solution is a better interface
between build systems and the compiler.
See the discussion on Zulip:

https://rust-lang.zulipchat.com/#narrow/channel/131828-t-compiler/topic/Improving.20communication.20interface.20between.20cargo.2Frustc

Fixes rust-lang/cargo#8010

### How should we test and review this PR?

Ensure `CFG_DISABLE_CROSS_TESTS` is not set,
and run `cargo t --test testsuite
always_emit_warnings_as_warnings_when_learning_target_info`

This also additionally adds `wasm32-unknown-unknown` target to Cargo's
CI.

### Additional information
2025-01-08 23:37:05 +00:00
Weihang Lo
4a88f924c6
test: extract checking installed target to a function 2025-01-08 17:27:25 -05:00
Ed Page
e6114c3395 fix(schema): Include lints sub-tables in packages
This was done by upgrading schemars.  Hard to tell what else was changed
because of the noise from the other changes in the layout.

Fixes #15030
2025-01-08 11:26:39 -06:00
Weihang Lo
4a1e2ea539
fix(schemas): Fix 'metadata' JSON Schema (#15033)
Instead of allowing any type in metadata, we were specifying fields like
`"string": "<any string>"`.

Found this when looking into #15030

<!--
Thanks for submitting a pull request 🎉! Here are some tips for you:

* If this is your first contribution, read "Cargo Contribution Guide"
first:
  https://doc.crates.io/contrib/
* Run `cargo fmt --all` to format your code changes.
* Small commits and pull requests are always preferable and easy to
review.
* If your idea is large and needs feedback from the community, read how:
  https://doc.crates.io/contrib/process/#working-on-large-features
* Cargo takes care of compatibility. Read our design principles:
  https://doc.crates.io/contrib/design.html
* When changing help text of cargo commands, follow the steps to
generate docs:

https://github.com/rust-lang/cargo/tree/master/src/doc#building-the-man-pages
* If your PR is not finished, set it as "draft" PR or add "WIP" in its
title.
* It's ok to use the CI resources to test your PR, but please don't
abuse them.

### What does this PR try to resolve?

Explain the motivation behind this change.
A clear overview along with an in-depth explanation are helpful.

You can use `Fixes #<issue number>` to associate this PR to an existing
issue.

### How should we test and review this PR?

Demonstrate how you test this change and guide reviewers through your
PR.
With a smooth review process, a pull request usually gets reviewed
quicker.

If you don't know how to write and run your tests, please read the
guide:
https://doc.crates.io/contrib/tests

### Additional information

Other information you want to mention in this PR, such as prior arts,
future extensions, an unresolved problem, or a TODO list.
-->
2025-01-08 19:05:19 +00:00
Ed Page
e8f3e5e0f2 chore(schema): Bump version 2025-01-08 11:26:27 -06:00
Weihang Lo
637c41e987
chore: bump to 0.87.0 2025-01-06 14:35:04 -05:00
Eric Huss
f96b7298a7 Update git2 2025-01-04 16:55:32 -08:00
renovate[bot]
13af53a518 chore(deps): update rust crate thiserror to v2 2025-01-02 13:18:39 -06:00
renovate[bot]
fb55f9b311
chore(deps): update rust crate itertools to 0.14.0 2025-01-01 02:26:09 +00:00
Sebastian Thiel
3a18044808
upgrade gix to the latest release 0.69.
The main benefit is that it won't facilitate hangs due to attempts
to read from untrackable directory entries, like names pipes or
sockets.

Related to https://github.com/GitoxideLabs/gitoxide/pull/1629
2024-12-22 19:15:00 +01:00
Ed Page
9a8ca867e2 chore: Bump cargo-test-support's version 2024-12-12 11:50:54 -06:00
Weihang Lo
5eb7480565
feat(SourceId): use stable hash from rustc-stable-hash
This helps `-Ztrim-paths` build a stable cross-platform path for the
registry and git sources. Sources files then can be found from the same
path when debugging.

It also helps cache registry index all at once for all platforms,
for example the use case in rust-lang/cargo#14795
(despite they should use `cargo vendor` instead IMO).

Some caveats:

* Newer cargo will need to re-download files for global caches
  (index files, git/registry sources).
  The old cache is still kept and used when running with older cargoes.
* Windows is not really covered by the "cross-platform" hash,
  because path prefix components like `C:` are always there.
  That means hashes of some sources kind,
  like local registry and local path,
  are not going to be real cross-platform stable.

There might be hash collisions if you have two registries under the same
domain. This won't happen to crates.io, as the infra would have to
intentionally put another registry on index.crates.io to collide.
We don't consider this is an actual threat model, so we are not going to
use any cryptographically secure hash algorithm like BLAKE3.

See also <https://github.com/rust-lang/cargo/issues/13171#issuecomment-2181465128>
2024-12-10 17:58:02 -05:00
Ed Page
70a6f011a4 chore(build-rs): Bump major version 2024-12-06 09:33:10 -06:00
Weihang Lo
6246988889
chore: Bump to 0.86.0 2024-12-02 13:59:14 -05:00
Eric Huss
d25c2691af
chore(deps): update rust crate cargo_metadata to 0.19.0 (#14878)
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [cargo_metadata](https://redirect.github.com/oli-obk/cargo_metadata) |
workspace.dependencies | minor | `0.18.1` -> `0.19.0` |

---

### Release Notes

<details>
<summary>oli-obk/cargo_metadata (cargo_metadata)</summary>

###
[`v0.19.0`](https://redirect.github.com/oli-obk/cargo_metadata/blob/HEAD/CHANGELOG.md#0190---2024-11-20)

[Compare
Source](https://redirect.github.com/oli-obk/cargo_metadata/compare/0.18.1...0.19.0)

##### Added

-   Re-exported `semver` crate directly.
-   Added implementation of `std::ops::Index<&PackageId>` for `Resolve`.
-   Added `pub fn is_kind(&self, name: TargetKind) -> bool` to `Target`.
- Added derived implementations of `PartialEq`, `Eq` and `Hash` for
`Metadata` and its members' types.
-   Added default fields to `PackageBuilder`.
- Added `pub fn new(name:version:id:path:) -> Self` to `PackageBuilder`
for providing all required fields upfront.

##### Changed

-   Bumped MSRV from `1.42.0` to `1.56.0`.
- Made `parse_stream` more versatile by accepting anything that
implements `Read`.
-   Converted `TargetKind` and `CrateType` to an enum representation.

##### Removed

- Removed re-exports for `BuildMetadata` and `Prerelease` from `semver`
crate.
- Removed `.is_lib(…)`, `.is_bin(…)`, `.is_example(…)`, `.is_test(…)`,
`.is_bench(…)`, `.is_custom_build(…)`, and `.is_proc_macro(…)` from
`Target` (in favor of adding `.is_kind(…)`).

##### Fixed

- Added missing `manifest_path` field to `Artifact`. Fixes
[#&#8203;187](https://redirect.github.com/oli-obk/cargo_metadata/issues/187).

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "before 5am on the first day of the
month" (UTC), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/rust-lang/cargo).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4xOS4wIiwidXBkYXRlZEluVmVyIjoiMzkuMTkuMCIsInRhcmdldEJyYW5jaCI6Im1hc3RlciIsImxhYmVscyI6W119-->
2024-12-01 19:14:29 +00:00
renovate[bot]
0937dd2a48
chore(deps): update rust crate gix to 0.68.0 2024-12-01 00:09:24 +00:00
renovate[bot]
59e42909cb
chore(deps): update rust crate cargo_metadata to 0.19.0 2024-12-01 00:09:18 +00:00
Weihang Lo
4240e722d4
test: requires attribute accepts string literals for cmds
The new syntax is key-value pair like `requires = "rustfmt"`,
comparing to the previous `requires_<cmd>`.
2024-11-29 22:23:08 -05:00
renovate[bot]
afb938628e
chore(deps): update msrv (3 versions) to v1.81 2024-11-29 18:10:03 +00:00
renovate[bot]
1ec49b8947
chore(deps): update msrv 2024-11-29 03:54:45 +00:00
Weihang Lo
10c255ad07
Add future-incompat warning against keywords in cfgs and add raw-idents (#14671)
### What does this PR try to resolve?

This PR tries to address this thread
https://github.com/rust-lang/cargo/pull/14649#discussion_r1790468829 in
#14649 regarding `cfg(true)`/`cfg(false)` (and keywords more generally)
which are wrongly accepted[^1] as ident.

To address this, this PR does two things:
1. it introduce a future-incompatibility warning against those (wrongly)
accepted keywords as ident
2. it add parsing for raw-idents (`r#true`) add suggest-it in the
warning

### How should we test and review this PR?

This PR should be reviewed commit-by-commit.
Tests are included in preliminary commits.

### Additional information

I added a new struct for representing `Ident`s which is rawness aware.
Which implied updating `cargo-platform` to `0.2.0` due to the API
changes.

r? @epage

[^1]:
https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=ccfb9c894dbf14e791c8ae7e4798efd0
2024-11-26 19:45:45 +00:00
Urgau
80dde854b4 Bump cargo-platform to 0.2.0 in preparation for cfg(<true/false>) 2024-11-25 21:51:18 +01:00
Weihang Lo
ceaaab39f0
chore: move supports-unicode to workspace deps 2024-11-22 17:27:43 -05:00
Weihang Lo
e5ce5e5588
Migrate build-rs to the Cargo repo (#14786)
### What does this PR try to resolve?

Fixes #12432

### How should we test and review this PR?

This pulls in https://github.com/cad97/build-rs at
eb389d1104dae2dc2eb4eafa9d6e821a7dcb45a7 with the following changes:
- `Cargo.toml` metadata
- Removal of `.github`, `.gitignore`, `Cargo.lock`

We'll need to integrate `test-lib` into our processes but that seemed
more invasive, so I wanted to leave that for a future PR.

### Additional information

Infra changes are being coordinated in
https://rust-lang.zulipchat.com/#narrow/channel/242791-t-infra/topic/Transfering.20.60build-rs.60.20crate.20to.20rust-lang/near/480779960

Context: per [Cargo's
charter](https://doc.crates.io/contrib/team.html#decision-process), we
approved this transfer in an
[FCP](https://github.com/rust-lang/cargo/issues/12432#issuecomment-2389528102).
2024-11-13 05:13:01 +00:00
Ed Page
fd544063ca chore(ci): Check for clippy correctness
The fact that we don't check for `derive_ord_xor_partial_ord ` almost bit us in #14663.

Instead of just enabling this one lint, I figured it'd be good to audit
all of the `deny` by default lints.
That is long enough that I was concerned about maintaining it (or
bikeshedding which to enable or disable).
All `deny` by default lints are `correctness` lints and I figure we
could just enable the group.

We normally opt-in to individual clippy lints.
From what I remember of that conversation, it mostly stems from how
liberal clippy is with making a lint `warn` by default.
It also makes an unpinned CI more brittle.
I figured clippy is more conservative about `deny` by default lints
and slower to add them that this is unlikely to be a problem.
2024-11-08 13:58:51 -06:00
Ed Page
54660c665e chore: Integrate build-rs into the workspace 2024-11-08 08:58:45 -06:00
Ed Page
a03adcf6e2 fix(test): Make redactions consistent with snapbox
I'm unsure how we should be replacing these use cases, so I'm exploring
keeping them but making them use snapbox under the hood.
Part of the intent of snapbox is that it provides you the building
blocks to make what you need.
2024-11-06 20:03:53 -06:00
bors
3dedb85a25 Auto merge of #14747 - saites:rustfix-transactional, r=weihanglo
Add transactional semantics to `rustfix`

### What does this PR try to resolve?

This PR adds transactional semantics to `rustfix::Data`, enabling `rustfix::CodeFix` to apply `Suggestion`s as atomic units and rollback partially-applied changes when they conflict with existing ones. The basic approach and goals are discussed [in a comment on issue 14699](https://github.com/rust-lang/cargo/issues/14699#issuecomment-2427501232). In that comment, I proposed a solution which extended the existing `State` enumeration, but described an alternative that simplifies the overall tracking of incoming changes; this PR implements the latter.

### How should we test and review this PR?

I've added an additional test and updated the existing ones. The tests in `parse_and_replace` already cover this case, particularly thanks to https://github.com/rust-lang/cargo/pull/14765 added by `@weihanglo.` It's still a good idea to experiment with `cargo clippy --fix` on repos that match the cases described in these open issues.

### Additional information

Fixes #14699
Fixes rust-lang/rust-clippy/issues/13549
2024-11-02 21:45:48 +00:00
Alexander Saites
f73b1d8c74 add transactional semantics to rustfix 2024-11-02 13:01:21 -07:00
TheSlapstickDictator
9b4f03a876 chore: update handlebars to v6, fix build error
DirectorySourceOptions is marked as #[non_exhaustive], and only
exposes the Default trait, so we need to instantiate a mutable
instance using default(), and then change tpl_extension to the
value we want.
2024-11-01 14:55:20 -07:00
bors
57ffbb6e78 Auto merge of #14766 - rust-lang:renovate/security-framework-3.x, r=ehuss
chore(deps): update rust crate security-framework to v3

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [security-framework](https://lib.rs/crates/security_framework) ([source](https://redirect.github.com/kornelski/rust-security-framework)) | workspace.dependencies | major | `2.11.1` -> `3.0.0` |

---

### Release Notes

<details>
<summary>kornelski/rust-security-framework (security-framework)</summary>

### [`v3.0.0`](https://redirect.github.com/kornelski/rust-security-framework/compare/v2.11.1...v3.0.0)

[Compare Source](https://redirect.github.com/kornelski/rust-security-framework/compare/v2.11.1...v3.0.0)

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "before 5am on the first day of the month" (UTC), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/rust-lang/cargo).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOC4xMzUuMiIsInVwZGF0ZWRJblZlciI6IjM4LjEzNS4yIiwidGFyZ2V0QnJhbmNoIjoibWFzdGVyIiwibGFiZWxzIjpbXX0=-->
2024-11-01 14:51:06 +00:00
renovate[bot]
1fad901e79
chore(deps): update rust crate security-framework to v3 2024-11-01 03:03:47 +00:00
renovate[bot]
48b163855f
chore(deps): update rust crate gix to 0.67.0 2024-11-01 00:02:25 +00:00
bors
cf9152007e Auto merge of #14683 - dacianpascu06:355adcad7, r=epage
Added unstable-schema generation for Cargo.toml

### What does this PR try to resolve?

Added unstable-schema feature that generates JsonSchema for Cargo.toml

See #12883
finished first step of [plan](https://github.com/rust-lang/cargo/issues/12883#issuecomment-2407648385)

### Information
In cargo-util-schemas,  run cargo test --feature unstable-schema  . If there have been any changes to manifest.schema.json, rerun with env variable SNAPSHOTS=overwrite  and it will update them.

### How should we test and review this PR?
In cargo-util-schemas run cargo test --features unstable-schema and it will generate manifest.schema.json
2024-10-24 21:26:44 +00:00
dacian
21ce69ef37 feat: unstable-json-schema generation for Cargo.toml 2024-10-25 00:05:11 +03:00
Ed Page
56f008da47 feat(complete): Include descriptions in zsh 2024-10-23 20:18:11 -05:00
renovate[bot]
341d619f66
chore(deps): update msrv 2024-10-19 01:35:59 -04:00