Skip to content

Merge pull request #92 from nnn-training/zen-study #97

Merge pull request #92 from nnn-training/zen-study

Merge pull request #92 from nnn-training/zen-study #97

Workflow file for this run

name: deploy
on:
push:
branches:
- main
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Use Node.js 20.9.0
uses: actions/setup-node@v4
with:
node-version: 20.9.0
cache: 'yarn'
- name: Cache Next.js build
uses: actions/cache@v4
with:
path: ${{ github.workspace }}/.next/cache
key: ${{ runner.os }}-nextjs-${{ hashFiles('**/yarn.lock') }}-${{ hashFiles('**/*.js', '**/*.jsx', '**/*.ts', '**/*.tsx') }}
restore-keys: ${{ runner.os }}-nextjs-${{ hashFiles('**/yarn.lock') }}-
- name: install
run: |
yarn install
- name: build
run: |
yarn build
env:
NEXT_PUBLIC_GITHUB_PAGES: true
- name: generate sitemap
run: |
npx next-sitemap
- name: Create .nojekyll
run: |
touch out/.nojekyll
- name: deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./out