From 616b2bfe7b10cdaeb049865d19b23aef7e08c080 Mon Sep 17 00:00:00 2001 From: Tim Crawford Date: Mon, 14 Aug 2023 11:07:52 -0600 Subject: [PATCH] scripts: Don't run git-lfs commands on CI The `deps.sh` script needs to be run to set up a new Jenkins workspace. The git-lfs commands fail with: mkdir /dev/null: not a directory To resolve this, either: 1: run `git lfs update --manual` for instructions on how to merge hooks. 2: run `git lfs update --force` to overwrite your hook. Just don't run them, since Jenkins is configured to perform the LFS pull when fetching the repo. Signed-off-by: Tim Crawford --- scripts/deps.sh | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/scripts/deps.sh b/scripts/deps.sh index a902d66..8662518 100755 --- a/scripts/deps.sh +++ b/scripts/deps.sh @@ -84,11 +84,14 @@ else exit 1 fi -msg "Installing GIT LFS hooks" -git lfs install +# Don't run on Jenkins +if [ -z "${CI}" ]; then + msg "Installing GIT LFS hooks" + git lfs install -msg "Downloading GIT LFS artifacts" -git lfs pull + msg "Downloading GIT LFS artifacts" + git lfs pull +fi msg "Initializing submodules" git submodule update --init --recursive --checkout --progress