Ignore Cargo.lock for libs in cargo-new#321
Merged
bors merged 1 commit intorust-lang:masterfrom Aug 6, 2014
Merged
Conversation
The lockfile should only be checked in for bins, not libs. Closes rust-lang#304
bors
added a commit
that referenced
this pull request
Aug 6, 2014
The lockfile should only be checked in for bins, not libs. Closes #304
bors
added a commit
to alexcrichton/cargo
that referenced
this pull request
Sep 2, 2014
The lockfile should only be checked in for bins, not libs. Closes rust-lang#304
weihanglo
added a commit
to weihanglo/cargo
that referenced
this pull request
Feb 11, 2022
Have traced down the issue. It feel like the original intent is to ignore `Cargo.lock` and `target` at project root but not subdirectories. 1. The original implementation did ignore root `/Cargo.lock`. rust-lang#321 2. Someday one wanted to support both gitignore and hgingore's syntax and removed the leading slash. rust-lang#1247 3. Later, one found that we should not ignore `target` other than under root directory and added `/target` back. rust-lang#4099 4. It turns out that the syntax is not compatible between gitignore and hgignore. Therefore, one started to use hgignore special syntax to handle `Cargo.lock`. rust-lang#4342 This commit rollbacks to what original implementation tries to do.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The lockfile should only be checked in for bins, not libs.
Closes #304