Skip to content

Commit

Permalink
changed it back
Browse files Browse the repository at this point in the history
  • Loading branch information
CloudLun committed Feb 22, 2024
1 parent c362d8a commit f3421d6
Showing 1 changed file with 16 additions and 15 deletions.
31 changes: 16 additions & 15 deletions .github/workflows/nextjs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,9 @@ jobs:
# Build job
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [18.17.1]
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Detect package manager
id: detect-package-manager
run: |
Expand All @@ -52,14 +49,20 @@ jobs:
exit 1
fi
- name: Setup Node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
node-version: "20"
cache: ${{ steps.detect-package-manager.outputs.manager }}
- name: Setup Pages
uses: actions/configure-pages@v3
uses: actions/configure-pages@v4
with:
# Automatically inject basePath in your Next.js configuration file and disable
# server side image optimization (https://nextjs.org/docs/api-reference/next/image#unoptimized).
#
# You may remove this line if you want to manage the configuration yourself.
static_site_generator: next
- name: Restore cache
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: |
.next/cache
Expand All @@ -72,14 +75,12 @@ jobs:
run: ${{ steps.detect-package-manager.outputs.manager }} ${{ steps.detect-package-manager.outputs.command }}
- name: Build with Next.js
run: ${{ steps.detect-package-manager.outputs.runner }} next build
- name: Export static files
run: npm run export
- name: List Files
run: ls -a
- name: Static HTML export with Next.js
run: ${{ steps.detect-package-manager.outputs.runner }} next export
- name: Upload artifact
uses: actions/upload-pages-artifact@v1
uses: actions/upload-pages-artifact@v3
with:
path: out
path: ./out

# Deployment job
deploy:
Expand All @@ -91,4 +92,4 @@ jobs:
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2
uses: actions/deploy-pages@v4

0 comments on commit f3421d6

Please sign in to comment.