ci: update

This commit is contained in:
MedzikUser 2022-05-10 16:09:25 +02:00
parent 57398b0410
commit 57a0a79796
No known key found for this signature in database
GPG Key ID: A5FAC1E185C112DB
2 changed files with 15 additions and 12 deletions

View File

@ -6,10 +6,10 @@ on:
- '**' - '**'
- '!website/**' - '!website/**'
pull_request: # pull_request:
paths: # paths:
- '**' # - '**'
- '!website/**' # - '!website/**'
workflow_dispatch: workflow_dispatch:

View File

@ -5,17 +5,14 @@ on:
branches: branches:
- main - main
paths: paths:
- website/** - 'website/**'
pull_request: pull_request:
paths: paths:
- website/** - 'website/**'
workflow_dispatch: workflow_dispatch:
env:
CARGO_TERM_COLOR: always
jobs: jobs:
build: build:
name: Next.js Build name: Next.js Build
@ -29,7 +26,7 @@ jobs:
uses: actions/setup-node@v3 uses: actions/setup-node@v3
- name: Install pnpm - name: Install pnpm
uses: pnpm/action-setup@v2.2.1 uses: pnpm/action-setup@v2
id: pnpm-install id: pnpm-install
with: with:
version: 7 version: 7
@ -48,11 +45,11 @@ jobs:
restore-keys: | restore-keys: |
${{ runner.os }}-pnpm-store- ${{ runner.os }}-pnpm-store-
- name: Cache next.js - name: Cache Next.js
uses: actions/cache@v3 uses: actions/cache@v3
with: with:
path: | path: |
${{ github.workspace }}/.next/cache ${{ github.workspace }}/website/.next/cache
key: ${{ runner.os }}-nextjs-${{ hashFiles('website/pnpm-lock.yaml') }}-${{ hashFiles('website/**.[jt]s', 'website/**.[jt]sx') }} key: ${{ runner.os }}-nextjs-${{ hashFiles('website/pnpm-lock.yaml') }}-${{ hashFiles('website/**.[jt]s', 'website/**.[jt]sx') }}
restore-keys: | restore-keys: |
${{ runner.os }}-nextjs-${{ hashFiles('website/pnpm-lock.yaml') }}- ${{ runner.os }}-nextjs-${{ hashFiles('website/pnpm-lock.yaml') }}-
@ -65,3 +62,9 @@ jobs:
- name: Export page - name: Export page
run: pnpm --prefix website run export run: pnpm --prefix website run export
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: website-static
path: website/out/**