Skip to content

Commit

Permalink
Create pages.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
Petalzu authored Apr 24, 2024
1 parent be27693 commit 426ce95
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions .github/workflows/pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,23 +3,25 @@ name: Pages
on:
push:
branches:
- master # default branch
- main # default branch

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
# If your repository depends on submodule, please see: https://github.com/actions/checkout
submodules: recursive
- name: Use Node.js 18.16.0
uses: actions/setup-node@v3
- name: Use Node.js 20
uses: actions/setup-node@v4
with:
node-version: '18.16.0'
# Examples: 20, 18.19, >=16.20.2, lts/Iron, lts/Hydrogen, *, latest, current, node
# Ref: https://github.com/actions/setup-node#supported-version-syntax
node-version: '20'
- name: Cache NPM dependencies
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: node_modules
key: ${{ runner.OS }}-npm-cache
Expand All @@ -30,7 +32,7 @@ jobs:
- name: Build
run: npm run build
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v2
uses: actions/upload-pages-artifact@v3
with:
path: ./public
deploy:
Expand All @@ -45,4 +47,4 @@ jobs:
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2
uses: actions/deploy-pages@v4

0 comments on commit 426ce95

Please sign in to comment.