-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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
rustdoc: add support for --emit=dep-info #91982
Labels
C-feature-request
Category: A feature request, i.e: not implemented / a PR.
T-rustdoc
Relevant to the rustdoc team, which will review and decide on the PR/issue.
Comments
matthiaskrgr
added a commit
to matthiaskrgr/rust
that referenced
this issue
Mar 1, 2025
…=notriddle Add rustdoc support for `--emit=dep-info[=path]` Fixes rust-lang#91982. This PR adds the `--emit=dep-info` command line flag support. It will be helpful for `cargo` development. cc `@epage` r? `@notriddle`
matthiaskrgr
added a commit
to matthiaskrgr/rust
that referenced
this issue
Mar 2, 2025
…=notriddle Add rustdoc support for `--emit=dep-info[=path]` Fixes rust-lang#91982. This PR adds the `--emit=dep-info` command line flag support. It will be helpful for `cargo` development. cc ``@epage`` r? ``@notriddle``
matthiaskrgr
added a commit
to matthiaskrgr/rust
that referenced
this issue
Mar 2, 2025
…=notriddle Add rustdoc support for `--emit=dep-info[=path]` Fixes rust-lang#91982. This PR adds the `--emit=dep-info` command line flag support. It will be helpful for `cargo` development. cc ```@epage``` r? ```@notriddle```
rust-timer
added a commit
to rust-lang-ci/rust
that referenced
this issue
Mar 3, 2025
Rollup merge of rust-lang#137684 - GuillaumeGomez:rustdoc-dep-info, r=notriddle Add rustdoc support for `--emit=dep-info[=path]` Fixes rust-lang#91982. This PR adds the `--emit=dep-info` command line flag support. It will be helpful for `cargo` development. cc ````@epage```` r? ````@notriddle````
This has been integrated into Cargo via rust-lang/cargo#15359, and will be available on nightly in a few days. |
20 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
C-feature-request
Category: A feature request, i.e: not implemented / a PR.
T-rustdoc
Relevant to the rustdoc team, which will review and decide on the PR/issue.
When running rustdoc, cargo currently doesn't know which files are used for each cargo target. Because of this, cargo conservatively assumes that a modification to any file in the project will require rebuilding the documentation for all targets. When running
rustc
, cargo uses the dep-info file to know which files each target is built from, so that it can know to only track for changes in those files. It would be helpful if rustdoc had a similar ability so that cargo could more precisely track the files.Since we probably don't want to pollute the output directory with this dep-info file, it would be good to ensure that it supports the
--emit dep-info=PATH
syntax thatrustc
has so that cargo could squirrel away the file somewhere else in the target directory.It might be nice if this also included paths passed to CLI options like
--extend-css
, though that is a stretch goal.Ideally it would be essentially the same as
rustc
, supporting the# env-dep:
comments as well to track environment variables that were used.The text was updated successfully, but these errors were encountered: