From 23e2d2a84642ab399bff041f3d5465b5e69b2586 Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Tue, 11 Jun 2024 10:05:42 -0400 Subject: [PATCH 1/2] Use deno compile to install deno bids-validator Make it less cumbersome and may be more efficient since produces a binary executable file --- .github/workflows/validate_datasets.yml | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/workflows/validate_datasets.yml b/.github/workflows/validate_datasets.yml index 815073bde..b9c45e711 100644 --- a/.github/workflows/validate_datasets.yml +++ b/.github/workflows/validate_datasets.yml @@ -71,11 +71,9 @@ jobs: run: | LOCAL_BIN=$HOME/.local/bin VALIDATOR=$LOCAL_BIN/bids-validator - mkdir -p $LOCAL_BIN - export PATH="$LOCAL_BIN:$PATH" - echo PATH="$PATH" >> $GITHUB_ENV - echo -e '#!/usr/bin/env'" -S deno run --allow-read --allow-write --allow-env --allow-net --allow-run\nimport 'https://github.com/bids-standard/bids-validator/raw/master/bids-validator/src/bids-validator.ts'" > $VALIDATOR - chmod +x $VALIDATOR + # Clone "lean" but with tags for versioning + git clone --filter=blob:none http://github.com/bids-standard/bids-validator + deno compile -o "$VALIDATOR" -A bids-validator/bids-validator/src/bids-validator.ts bids-validator --version shell: bash From 59e9191865f6f31abd4e13aee921133be6b55c50 Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Tue, 11 Jun 2024 10:10:16 -0400 Subject: [PATCH 2/2] Do pushd/popd dance to place bids-validator repo aside --- .github/workflows/validate_datasets.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/validate_datasets.yml b/.github/workflows/validate_datasets.yml index b9c45e711..19ededf13 100644 --- a/.github/workflows/validate_datasets.yml +++ b/.github/workflows/validate_datasets.yml @@ -72,8 +72,10 @@ jobs: LOCAL_BIN=$HOME/.local/bin VALIDATOR=$LOCAL_BIN/bids-validator # Clone "lean" but with tags for versioning + pushd .. git clone --filter=blob:none http://github.com/bids-standard/bids-validator deno compile -o "$VALIDATOR" -A bids-validator/bids-validator/src/bids-validator.ts + popd bids-validator --version shell: bash