diff --git a/.github/workflows/deploy-gh-pages.yaml b/.github/workflows/deploy-gh-pages.yaml new file mode 100644 index 0000000..ec6e3b0 --- /dev/null +++ b/.github/workflows/deploy-gh-pages.yaml @@ -0,0 +1,35 @@ +name: Deploy gh pages + +on: + push: + branches: + - main + +jobs: + build-and-deploy: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Setup Node + uses: actions/setup-node@v4 + with: + node-version: 20 + + - uses: actions/cache@v4 + with: + path: ~/.npm + key: node-${{ hashFiles('**/package-lock.json') }} + restore-keys: | + node- + + - name: Build + run: | + npm ci + npm run build + + - name: Deploy + uses: peaceiris/actions-gh-pages@v4 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: ./dist \ No newline at end of file