Commit graph

10916 commits

Author SHA1 Message Date
Eric Huss 81defa6d1e Consolidate doc collision detection. 2021-05-30 19:39:48 -07:00
bors b1684e2849 Auto merge of #9499 - weihanglo:tree-depth, r=ehuss
Add `--depth` option for `cargo-tree`

Part of #8105

Note that the `--depth` option only regards the "tree" depth but not dependency depth.

## To resolve

Bike-shedding naming problem: `-L,--level`  or `--depth`?
2021-05-28 16:27:46 +00:00
Weihang Lo da2327f129
Merge branch 'master' into tree-depth 2021-05-28 23:27:42 +08:00
bors 238a9fa71f Auto merge of #9488 - weihanglo:issue-9165, r=ehuss
`cargo tree -e no-proc-macro` to hide procedural macro dependencies

Probably resolves #9165

`cargo tree -e no-proc-macro` now hides procedural macro dependencies.

Note that when passed with `--invert <spec>`, the spec's reverse proc-macro dependencies are also hidden. Is this desired result?

Also, since I want `-p <spec>` and `-i <spec>` works with any valid package-id in the project, the filter logic is written in print stage instead of graph build stage
2021-05-28 14:55:26 +00:00
Weihang Lo c2fd499eac
fix: remove unnecessary match bindings
Co-authored-by: Eric Huss <eric@huss.org>
2021-05-28 07:25:57 +08:00
bors 2f3df16921 Auto merge of #9508 - dtolnay-contrib:semver, r=ehuss
Update to semver 1.0.0

I am working on a 1.0.0 of the `semver` crate some time this week. It would be good to confirm Cargo will be able to use it, beforehand!

It's a from-scratch rewrite, but https://github.com/dtolnay/semver/issues/237 has code to compare against 0.10.0 (currently used by Cargo) how every possible version requirement currently published to crates.io matches against every possible crate version. The differences are all broken syntax like `^0-.11.0` previously parsing with ".11.0" as a pre-release string (which is invalid, because pre-release are not allowed to contain empty dot-separated identifiers) and `~2.0-2.2` previously parsing with "2.2" as a pre-release string, when the user almost certainly meant `>=2.0, <=2.2`. I'm not sure how much of those you want to add code into Cargo to preserve behavior, but I would be happy to do it.
2021-05-27 22:34:28 +00:00
bors cc75485f72 Auto merge of #9517 - alexcrichton:update-rrar, r=ehuss
Update tar dependency to 0.4.35

Pulls in a fix which should avoid 0 mtime files from showing up.

Closes #9512
2021-05-27 22:08:08 +00:00
Alex Crichton a02b6e5bfc Update tar dependency to 0.4.34
Pulls in a fix which should avoid 0 mtime files from showing up.

Closes #9512
2021-05-27 14:16:59 -07:00
David Tolnay 7ace4470c4
Update to semver 1.0.0 2021-05-26 14:39:13 -07:00
David Tolnay 396bdd3a89
Remove parsing of broken version syntax from 5 years ago 2021-05-26 14:37:39 -07:00
David Tolnay 3b62e466ec
Update to semver 1.0.0-rc 2021-05-25 17:42:05 -07:00
bors e931e4796b Auto merge of #9486 - Dirbaio:link-arg-bin, r=ehuss
Add `cargo:rustc-link-arg-bin` flag.

This PR implements a `cargo:rustc-link-arg-bin` command to specify per-binary link args from build scripts. This follows the suggestion from the tracking issue #9426.

Syntax is `cargo:rustc-link-arg-bin=BIN_NAME=ARG`

This was previously possible to do using the `#[link_args=".."]` attribute, but it was removed in rust-lang/rust#83820 in favor of the Cargo extra-link-args feature, which can currently not specify different link args for different bins in the same crate. This PR adds back the ability to do that.
2021-05-24 16:17:27 +00:00
bors f898eff9b9 Auto merge of #9473 - lf-:meow, r=ehuss
Add a cargo-doc.browser config option

The idea of this option is to allow cargo to use a separate browser from
the rest of the system. My motivation in doing this is that I want to
write a script that adds a symbolic link in some web root on my system
such that I can access my docs via the http protocol to avoid the
limitations of the file protocol that are accessibility problems for me.
For instance, zoom is not retained across multiple pages and Stylus
filters don't work well.
2021-05-24 15:54:16 +00:00
bors 07340c95c6 Auto merge of #9437 - In-line:unknown-feature-resolver-1, r=ehuss
Fix bug when with resolver = "1" non-virtual package was allowing unknown features
2021-05-24 15:20:48 +00:00
Eric Huss 61b762b9ff Remove unneeded masquerade_as_nightly_cargo.
This was accidentally missed when it was stabilized.
2021-05-24 08:18:14 -07:00
Jade 6128b54b8a docs: cargo-doc.browser -> doc.browser; mention in cargo-{rust,}doc.1 2021-05-20 22:52:49 -07:00
Dario Nieuwenhuis daffd0a42b Add unstable docs for cargo:rustc-link-arg-bin=foo=--bar 2021-05-20 21:50:50 +02:00
Dario Nieuwenhuis 160756368f Add test for cargo:rustc-link-arg-bin=foo=--bar 2021-05-20 21:41:17 +02:00
Dario Nieuwenhuis 5382aa650a Add rustc-link-arg-bin key to specify per-bin link args. 2021-05-20 20:47:54 +02:00
Dario Nieuwenhuis 0895469aec Allow LinkType to access the Target for checking if it applies. 2021-05-20 20:47:12 +02:00
Alik Aslanyan 1839ded4aa
Cargo fmt 2021-05-20 08:36:01 +04:00
Alik Aslanyan 766c3bbcb8 Merge branch 'master' of github.com:rust-lang/cargo into unknown-feature-resolver-1 2021-05-20 08:34:48 +04:00
Alik Aslanyan 2762dcdbe9
Revert fmt 2021-05-20 08:33:57 +04:00
Alik Aslanyan ca0cce760e
Revert unnecessary changes 2021-05-20 08:31:57 +04:00
Weihang Lo 40791da11f
doc: generated via build-man.sh 2021-05-19 09:59:02 +08:00
Weihang Lo d8334d5a6d
doc(cargo-tree): add --depth option 2021-05-19 09:59:01 +08:00
Weihang Lo 62d811d9f7
test(cargo-tree): --depth option 2021-05-19 09:29:47 +08:00
Weihang Lo 7cbc365da8
feat: new --depth option for cargo tree 2021-05-19 09:29:46 +08:00
bors 6ca6dd0bff Auto merge of #9493 - ehuss:contrib-git-url, r=alexcrichton
Add GitHub link to contributor guide.

This adds a small icon on each page that links back to the GitHub source.
2021-05-18 21:48:52 +00:00
bors 0d9bc9dfad Auto merge of #9498 - ehuss:rustup-windows-workaround, r=alexcrichton
Add temporary fix for rustup on windows in CI.

This adds a temporary fix for rustup on the Windows CI runners. The GitHub image updated to rustup 1.24.1 which has an issue (https://github.com/rust-lang/rustup/issues/2759) causing them to fail.  This is fixed in 1.24.2.  I believe the images are updated on roughly a weekly basis, and from what I can see the image just downloads the most recently release, so hopefully this will be fixed on GitHub's side in roughly a week. Until then, this will force rustup to update.

Note: Self updates aren't available on macOS images, but they seem to work on the others.
2021-05-18 20:47:05 +00:00
Eric Huss 65ca4e0d1e Add temporary fix for rustup on windows in CI. 2021-05-18 13:33:35 -07:00
bors f0b39fc853 Auto merge of #9495 - dunkyl:master, r=ehuss
3 typos and some capitalization

3 typos and...

Most of the docs use "command-line" instead of "commandline", changed where it made sense (in plain text).

Most of the docs also use "SemVer" instead of "semver", changed for consistency except for the "semver trick" (consistent with context).

I believe these are the correct files to change, since none of these changes are in doc/man?
2021-05-18 14:05:33 +00:00
dunkyl 4d8c0bb6b2 Capitalization
SemVer

Rust capitalization
2021-05-17 23:05:23 -07:00
dunkyl c4635dabce typo 2021-05-17 22:49:17 -07:00
dunkyl 67900818cf dash-style command-line 2021-05-17 22:18:10 -07:00
dunkyl 49bb10d7ed 2 typos 2021-05-17 22:17:31 -07:00
Eric Huss 073c8f4baf Add GitHub link to contributor guide. 2021-05-17 14:52:37 -07:00
Jade 50486be0c0 testsuite/doc: Check the arguments used to invoke the browser
Previously we apparently weren't doing this as we weren't checking
stdout.
2021-05-15 18:59:24 -07:00
Jade ed46a9a4de test path and args 2021-05-15 14:23:44 -07:00
Jade 6ea1eb3f7e Move browser setting to [doc], use PathAndArgs 2021-05-15 13:23:55 -07:00
Weihang Lo dc5f530c5c
refactor: move arg manipulations into commands 2021-05-16 02:03:43 +08:00
Weihang Lo 0ad53bfde9
doc: generated via build-man.sh 2021-05-16 02:02:50 +08:00
Weihang Lo ecd730e292
doc: add no-proc-macro description for --edges 2021-05-16 02:01:50 +08:00
Weihang Lo a5139b96b9
test: cargo tree incorrect --edges arg 2021-05-16 02:00:56 +08:00
Weihang Lo c8af63795e
test: assert no-proc-macro for existing tests 2021-05-16 02:00:22 +08:00
Weihang Lo b5a119737f
feat: add no-proc-macro for --edges option 2021-05-16 01:59:33 +08:00
bors 44596fa2b1 Auto merge of #9484 - kklibo:master, r=ehuss
fix 6 typos

Fixes #9483
2021-05-14 00:59:52 +00:00
kklibo 50da820e52 fix 6 typos 2021-05-13 17:36:02 -07:00
Alik Aslanyan 503a8670d9
Another way to fix 2021-05-13 11:30:46 +04:00
bors 070e459c2d Auto merge of #9468 - PaulDance:fix-rustdoc-warnings, r=ehuss
Fix rustdoc warnings

Change some small parts of the unit documentation in order to resolve warnings emitted when running `cargo doc` from the root of this project. It should help reduce the noise when checking that new or updated documentation builds correctly.

See the commit messages for details about the modifications themselves, although they should be rather simple.

Cheers,
Paul.
2021-05-11 18:12:23 +00:00