From 65d54e7bbeec41f2c61e61581a78758240e58dec Mon Sep 17 00:00:00 2001 From: "Tobin C. Harding" Date: Wed, 27 Mar 2024 11:15:35 +1100 Subject: [PATCH] Add script to update-lock-files Copy the script from `rust-bitcoin`, also add a `just` command to call it. --- contrib/update-lock-files.sh | 11 +++++++++++ justfile | 6 +++++- 2 files changed, 16 insertions(+), 1 deletion(-) create mode 100755 contrib/update-lock-files.sh diff --git a/contrib/update-lock-files.sh b/contrib/update-lock-files.sh new file mode 100755 index 000000000..02ba1f7c8 --- /dev/null +++ b/contrib/update-lock-files.sh @@ -0,0 +1,11 @@ +#!/usr/bin/env bash +# +# Update the minimal/recent lock file + +set -euo pipefail + +for file in Cargo-minimal.lock Cargo-recent.lock; do + cp --force "$file" Cargo.lock + cargo check + cp --force Cargo.lock "$file" +done diff --git a/justfile b/justfile index fd8c17a7f..d98737dc2 100644 --- a/justfile +++ b/justfile @@ -31,4 +31,8 @@ sane: lint # Check for API changes. check-api: - ./contrib/check-for-api-changes.sh \ No newline at end of file + ./contrib/check-for-api-changes.sh + +# Update the lock files. +update-lock-files: + ./contrib/update-lock-files.sh