Skip to content

Commit

Permalink
refactor: Update GitHub Pages deployment workflow to use Node.js 16 a…
Browse files Browse the repository at this point in the history
…nd fix build step order
  • Loading branch information
jyzhao committed Aug 13, 2024
1 parent 4fecceb commit e0a038c
Showing 1 changed file with 15 additions and 5 deletions.
20 changes: 15 additions & 5 deletions .github/workflows/publish-to-github-page.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,18 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Install & build
run: |
echo "${{secrets.GITHUB_TOKEN}}" | gh auth login --with-token
npm i
npm run deploy
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '16'

- name: Install dependencies
run: npm install

- name: Build the React app
run: npm run build

- name: Deploy to GitHub Pages
run: npm run deploy
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit e0a038c

Please sign in to comment.