Add volta config to keep our env consistent between machines #94
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: volta-cli/action@v1 | |
- name: Cache pnpm modules | |
uses: actions/cache@v3 | |
with: | |
path: ~/.pnpm-store | |
key: ${{ runner.os }}-${{ hashFiles('**/pnpm-lock.yaml') }} | |
restore-keys: | | |
${{ runner.os }}- | |
- uses: pnpm/action-setup@v2.2.1 | |
with: | |
version: 7.1.2 | |
- name: Install Dependencies | |
run: pnpm install | |
- name: Build | |
run: pnpm build:docs | |
- name: Generate Fallback Page | |
run: cp test-app/dist/index.html test-app/dist/404.html | |
- name: Upload to GitHub Pages | |
uses: JamesIves/github-pages-deploy-action@4.1.4 | |
with: | |
branch: gh-pages | |
folder: test-app/dist |