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

cargo vendor purges the vendor directory, including its .git #7109

Closed
WildCryptoFox opened this issue Jul 9, 2019 · 1 comment · Fixed by #7242
Closed

cargo vendor purges the vendor directory, including its .git #7109

WildCryptoFox opened this issue Jul 9, 2019 · 1 comment · Fixed by #7242
Labels

Comments

@WildCryptoFox
Copy link

WildCryptoFox commented Jul 9, 2019

Running cargo vendor removes the /vendor/ directory, including any .git directory if one exists. I'd like to use git to manage the vendor, as a git module; but it is currently hostile to that plan.

Steps

  1. use git
  2. try cargo vendor
  3. realize vendor didn't appreciate git

Possible Solution(s)

Remove the contents of the /vendor/ making an exception for anything starting with a dot.

@WildCryptoFox WildCryptoFox added the C-bug Category: bug label Jul 9, 2019
bors added a commit that referenced this issue Aug 13, 2019
 `cargo vendor`: Don't delete hidden top-level files.

`cargo vendor` (without `--no-delete`) will delete all files in the `vendor/` directory when it starts. This changes it so that it will skip any entries starting with a dot. This allows one to track the vendor directory with a source control system like git.

Closes #7109

(Note: two commits, one is a test change.)
@WildCryptoFox
Copy link
Author

Thank you @alexcrichton !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants