Skip to content

Commit

Permalink
chore(ci): add pnpm init
Browse files Browse the repository at this point in the history
  • Loading branch information
dorayx committed Sep 5, 2023
1 parent 25be757 commit fd361bc
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 6 deletions.
45 changes: 40 additions & 5 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,46 @@ jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: bazelbuild/setup-bazelisk@v2
- uses: actions/cache@v3
- name: Checkout
uses: actions/checkout@v3

- name: Install NodeJS
uses: actions/setup-node@v3
with:
node-version-file: .nvmrc

- name: Install pnpm
uses: pnpm/action-setup@v2
with:
run_install: false

- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- name: Setup pnpm cache
uses: actions/cache@v3
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install Bazelisk
uses: bazelbuild/setup-bazelisk@v2

- name: Setup bazel cache
uses: actions/cache@v3
with:
path: "~/.cache/bazel"
key: bazel
- run: bazel build //...
- run: bazel test //...

- name: Install NodeJS dependencies
run: pnpm install

- name: Build with Bazel
run: bazel build //...

- name: Run tests with Bazel
run: bazel test //...
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,6 @@
"typescript": "^5.1.3",
"vite": "^4.4.5",
"vitest": "^0.34.3"
}
},
"packageManager": "[email protected]"
}

0 comments on commit fd361bc

Please sign in to comment.