ci: install zstd binary

This commit is contained in:
MDLeom 2024-06-11 12:06:41 +00:00
parent 30c33c0ad3
commit a2c810cfb5
No known key found for this signature in database
GPG Key ID: 06C236E63CBC68AA
1 changed files with 13 additions and 4 deletions

View File

@ -23,11 +23,20 @@ jobs:
key: ${{ runner.os }}-npm-cache key: ${{ runner.os }}-npm-cache
restore-keys: ${{ runner.os }}-npm-cache restore-keys: ${{ runner.os }}-npm-cache
- name: Install Dependencies - name: Install Dependencies
run: npm install
- name: Determine zstd binary version
shell: bash
run: | run: |
npm install case "$RUNNER_OS" in
npm install @mongodb-js/zstd-linux-x64-musl \ "Linux")
@mongodb-js/zstd-win32-x64-msvc \ echo "PLATFORM=linux-x64-gnu" >> "$GITHUB_ENV" ;;
@mongodb-js/zstd-darwin-arm64 "Windows")
echo "PLATFORM=win32-x64-msvc" >> "$GITHUB_ENV" ;;
"macOS")
echo "PLATFORM=darwin-arm64" >> "$GITHUB_ENV" ;;
esac
- name: Install zstd binary
run: npm install "@mongodb-js/zstd-${PLATFORM}"
- name: Test - name: Test
run: npm run test run: npm run test
env: env: