Uh oh!
There was an error while loading. Please reload this page.
move file-extension based .gitignore down to src/ - #53768
Conversation
rust-highfive
commented
Aug 28, 2018
(rust_highfive has picked a reviewer for you, use r? to override) |
nikomatsakis
commented
Aug 28, 2018
@bors r+ rollup no strong opinion here |
bors
commented
Aug 28, 2018
📌 Commit 6628d39 has been approved by |
move file-extension based .gitignore down to src/ Currently, it for example ignores `*.rlib` files in the repository root -- which I think is wrong; I sometimes get these files when I call rustc directly and I do want them cleaned up, not ignored. No such files are created during the normal build process.
uberjay
commented
Aug 29, 2018
At the risk of commenting without fully understanding what's going on here: I find this confusing -- doesn't it effectively say that you want git to track changes in the repo root for files with these extensions? Meaning, with this change running |
move file-extension based .gitignore down to src/ Currently, it for example ignores `*.rlib` files in the repository root -- which I think is wrong; I sometimes get these files when I call rustc directly and I do want them cleaned up, not ignored. No such files are created during the normal build process.
nikomatsakis
commented
Aug 29, 2018
That is correct; on the other hand, Maybe I was hasty in r+'ing, though, and should have done a broader survey. My bad. cc @rust-lang/compiler @rust-lang/libs and other people who hack on this repo. Do you have opinions? :) |
nagisa
commented
Aug 29, 2018
I don’t mind this change. I doubt people with a habit of littering around their repository will be using |
move file-extension based .gitignore down to src/ Currently, it for example ignores `*.rlib` files in the repository root -- which I think is wrong; I sometimes get these files when I call rustc directly and I do want them cleaned up, not ignored. No such files are created during the normal build process.
The way I use git (and, from my experience, the way it is frequently used), I wasn't aware people would do |
nikomatsakis
commented
Aug 29, 2018
Yeah, I actually would be pretty surprised if anyone used It makes sense to only ignore files which are expected to be created! Thanks for humoring me. :) |
move file-extension based .gitignore down to src/ Currently, it for example ignores `*.rlib` files in the repository root -- which I think is wrong; I sometimes get these files when I call rustc directly and I do want them cleaned up, not ignored. No such files are created during the normal build process.
Rollup of 20 pull requests Successful merges: - #51760 (Add another PartialEq example) - #53113 (Add example for Cow) - #53129 (remove `let x = baz` which was obscuring the real error) - #53389 (document effect of join on memory ordering) - #53472 (Use FxHash{Map,Set} instead of the default Hash{Map,Set} everywhere in rustc.) - #53476 (Add partialeq implementation for TryFromIntError type) - #53513 (Force-inline `shallow_resolve` at its hottest call site.) - #53655 (set applicability) - #53702 (Fix stabilisation version for macro_vis_matcher.) - #53727 (Do not suggest dereferencing in macro) - #53732 (save-analysis: Differentiate foreign functions and statics.) - #53740 (add llvm-readobj to llvm-tools-preview) - #53743 (fix a typo: taget_env -> target_env) - #53747 (Rustdoc fixes) - #53753 (expand keep-stage --help text) - #53756 (Fix typo in comment) - #53768 (move file-extension based .gitignore down to src/) - #53785 (Fix a comment in src/libcore/slice/mod.rs) - #53786 (Replace usages of 'bad_style' with 'nonstandard_style'.) - #53806 (Fix UI issues on Implementations on Foreign types) Failed merges: r? @ghost
bors
commented
Aug 31, 2018
☔ The latest upstream changes (presumably #53832) made this pull request unmergeable. Please resolve the merge conflicts. |
petrochenkov
commented
Sep 1, 2018
Oh no.
I often call rustc directly too, like this or similar and I want the produced files to be ignored, so they do not litter git-gui or git status.
In my case this is expected temporary data in the repository, exactly something that needs to be ignored. |
crlf0710
commented
Sep 1, 2018
@petrochenkov maybe you can edit your |
gitignore: add comment explaining policy Based on rust-lang#63307 (comment), I added a comment what I think should be gitignored and what not. This is just a proposal, obviously. Also see rust-lang#53768 for some more discussion. The summary is that if there are junk files that you create locally and are fine leaving around (such as `mir_dump`), git has the option for you to add them to `.git/info/exclude`. Others might prefer to keep their working dir clean of those same junk files, so we shouldn't just ignore them for everyone. I then also cleaned up a few more things, but there were many things that I had no idea where they came from so I didn't touch them.
gitignore: add comment explaining policy Based on rust-lang#63307 (comment), I added a comment what I think should be gitignored and what not. This is just a proposal, obviously. Also see rust-lang#53768 for some more discussion. The summary is that if there are junk files that you create locally and are fine leaving around (such as `mir_dump`), git has the option for you to add them to `.git/info/exclude`. Others might prefer to keep their working dir clean of those same junk files, so we shouldn't just ignore them for everyone. I then also cleaned up a few more things, but there were many things that I had no idea where they came from so I didn't touch them.
…um,Centril keep the root dir clean from debugging We landed this before with rust-lang#63307 but recently in rust-lang#65630 the IMO bad ignore crept back in. If you regularly do graphviz-based debugging and you are fine leaving junk in the rustc root dir, please configure your local `.git/info/exclude`. But most people working on rustc don't work with graphciz all that often (I for once never did), and not everyone likes to have stray generated files in their source dirs. Also Cc rust-lang#63373rust-lang#53768@ecstatic-morse@Mark-Simulacrum
…um,Centril keep the root dir clean from debugging We landed this before with rust-lang#63307 but recently in rust-lang#65630 the IMO bad ignore crept back in. If you regularly do graphviz-based debugging and you are fine leaving junk in the rustc root dir, please configure your local `.git/info/exclude`. But most people working on rustc don't work with graphciz all that often (I for once never did), and not everyone likes to have stray generated files in their source dirs. Also Cc rust-lang#63373rust-lang#53768@ecstatic-morse@Mark-Simulacrum
Currently, it for example ignores
*.rlibfiles in the repository root -- which I think is wrong; I sometimes get these files when I call rustc directly and I do want them cleaned up, not ignored. No such files are created during the normal build process.