Closed mzji closed 7 years ago
But this is a library
Wait, there is a [[bin]]
section in the Cargo.toml, so it at least contains one binary... right?
Edit: Most third-party cargo subcommands in the official list have a Cargo.lock in their repository, for example: cargo-tree/Cargo.lock.
There's a [[bin]]
exactly because it's a library.
Re: edit: that's because cargo-tree
isn't a library
cargo-edit is a library and contains a binary, its repo contains a Cargo.lock.
Maybe killercup views it primarily as an exec, secondarily as a library, v0v. This is a library first, an exec second (think of the exec like an example, which it basically is (and should be)).
Ah, OK, so maybe Cargo.lock should be added into the .gitignore , just like Clippy
It is in .gitignore
Ah got it. Thanks for the explain! Not very familiar with the syntax of .gitignore , almost misinterpreted.
I like to use an inverted .gitignore
- everything is ignored except the files specified with !
before them
As per the Cargo reference, for programs, Cargo.lock should be in the repository.