rust: Treat Cargo.lock files as opaque

Cargo.lock files pin the versions of all transitive dependencies, and
are left that way by Cargo unless requested manually (`cargo update`) or
necessitated by a change in dependencies (if the manually maintained
Cargo.toml says `>0.5.2` and .lock says `0.5.1`, the latter is reset).

They are fixed (as opposed to .gitignoring them and letting each user
autogenerate them) to ensure that third party changes do not break RIOT
CI builds; for updates, the changes from a `cargo update` can still be
committed and then run through CI checks. (This is analogous to how pkg
versions are pinned).

They are set to binary because their diffs are usually not practical to
read.
This commit is contained in:
chrysn 2021-12-14 13:22:32 +01:00
parent 732c369b7e
commit 1273f2940f

1
.gitattributes vendored
View File

@ -1,5 +1,6 @@
*.a binary
*.patch binary
Cargo.lock binary
# Default conflict marker size is 7 which causes some of the headings in
# release-notes.txt to trigger git diff --check: 'leftover conflict marker'
# when the heading is exactly 7 characters long.