Skip to content

Commit 14eb04b

Browse files
authored
Merge pull request #130 from rust-osdev/cargo-lock
workspace: check in Cargo.lock
2 parents 678bcc1 + c45fd68 commit 14eb04b

File tree

3 files changed

+98
-4
lines changed

3 files changed

+98
-4
lines changed

.github/workflows/_build-rust.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,9 @@ jobs:
5858
~/.cargo/registry/cache/
5959
~/.cargo/git/db/
6060
target/
61-
# We do not have a Cargo.lock here, so I hash Cargo.toml
62-
key: ${{ runner.os }}-rust-${{ inputs.rust-version }}-cargo-${{ hashFiles('**/Cargo.toml') }}
63-
restore-keys: ${{ runner.os }}-cargo-${{ inputs.rust-version }}
61+
# Hash over Cargo.toml and Cargo.lock, as this might be copied to
62+
# projects that do not have a Cargo.lock in their repository tree!
63+
key: ${{ runner.os }}-rust-${{ inputs.rust-version }}-cargo-${{ hashFiles('**/Cargo.toml', '**/Cargo.lock') }}
6464
- run: cargo version
6565
- name: Build (library)
6666
run: cargo build --target ${{ inputs.rust-target }} --features ${{ inputs.features }}

.gitignore

-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
11
target
2-
Cargo.lock
32
*.swp

Cargo.lock

+95
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)