Skip to content
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

Add Cargo.lock to gitignore #71

Merged
merged 1 commit into from
Sep 12, 2024
Merged

Conversation

nicoburns
Copy link
Contributor

We don't have Cargo.lock committed, so we should ignore it. Currently it keeps showing up as an untracked file which makes it hard to avoid accidentally committing it as part of unrelated changes. .gitignore is currently not upstream but is part of the "Initial downstream commit".

@Loirooriol
Copy link
Contributor

Shouldn't we commit Cargo.lock instead?

@mrobinson
Copy link
Member

Cargo.lock used to be committed, but it increased the size of our diff from upstream. Ultimately, Stylo is used in Servo which has its own Cargo.lock file. As long as thing keep compiling here and in Servo, I think we do not have to commit Cargo.lock. It's a bit unusual for crates to check in their Cargo.lock file in any case.

@nicoburns
Copy link
Contributor Author

It's a bit unusual for crates to check in their Cargo.lock file in any case.

I believe there was recently a change of advice from the Rust/Cargo teams about this. They previously recommended that libraries don't check in Cargo.toml, and they now weakly recommend doing so. But I think it's pretty much a toss up in terms of advantages/disadvantages, and many crates still don't. As it's a bit of a pain for Stylo I suggest we just don't for now (we can always commit it again later, but I would personally consider that low priority).

Copy link
Member

@mrobinson mrobinson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is okay for now.

@mrobinson mrobinson added this pull request to the merge queue Sep 12, 2024
Merged via the queue into servo:main with commit 1aac091 Sep 12, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants