Skip to content

Merge pull request #23 from remarkablegames/dependabot/npm_and_yarn/t… #79

Merge pull request #23 from remarkablegames/dependabot/npm_and_yarn/t…

Merge pull request #23 from remarkablegames/dependabot/npm_and_yarn/t… #79

Workflow file for this run

name: build
on: [push, pull_request]
permissions:
contents: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version-file: .nvmrc
cache: npm
- name: Install dependencies
run: npm install --prefer-offline
- name: Set environment variables
run: |
echo "URL=$(jq -r .homepage package.json)" >> $GITHUB_ENV
- name: Build
run: npm run build -- --public-url ${{ env.URL }}
- name: Deploy
if: github.ref == 'refs/heads/master'
uses: JamesIves/github-pages-deploy-action@v4
with:
branch: gh-pages
folder: dist