mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-16 06:45:16 +01:00
19 lines
479 B
Bash
Executable file
19 lines
479 B
Bash
Executable file
#!/bin/sh
|
|
|
|
# This updates cargo-lock.patch for the b3sum version listed in default.nix.
|
|
|
|
set -eu -o verbose
|
|
|
|
here=$PWD
|
|
version=$(cat default.nix | grep '^ version = "' | cut -d '"' -f 2)
|
|
checkout=$(mktemp -d)
|
|
git clone -b "$version" --depth=1 https://github.com/BLAKE3-team/BLAKE3 "$checkout"
|
|
cd "$checkout"
|
|
|
|
(cd b3sum && cargo generate-lockfile)
|
|
mv b3sum/Cargo.lock ./
|
|
git add -f Cargo.lock
|
|
git diff HEAD -- Cargo.lock > "$here"/cargo-lock.patch
|
|
|
|
cd "$here"
|
|
rm -rf "$checkout"
|