Skip to content

Commit 047bde4

Browse files
authored
Update build.yml
again...
1 parent 91bd775 commit 047bde4

1 file changed

Lines changed: 8 additions & 13 deletions

File tree

.github/workflows/build.yml

Lines changed: 8 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,8 @@ env:
44
deployToRepo: gh-pages
55

66
on:
7-
# Triggers the workflow on push and pull request events but only for the master branch
87
push:
98
branches: [master]
10-
# Allows you to run this workflow manually from the Actions tab.
119
workflow_dispatch:
1210

1311
jobs:
@@ -16,40 +14,37 @@ jobs:
1614

1715
strategy:
1816
matrix:
19-
node-version: [23.x]
17+
node-version: [23.x]
2018

2119
steps:
22-
# Checks-out your repository under $GITHUB_WORKSPACE, fetching full history
2320
- name: Checkout
2421
uses: actions/checkout@v4
2522
with:
26-
fetch-depth: 0
27-
28-
# Setup pnpm
23+
fetch-depth: 0 # Fetches history for real dates
24+
25+
- name: Fix Git Safe Directory
26+
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
27+
2928
- name: Setup pnpm
3029
uses: pnpm/action-setup@v4
3130

32-
# Setup Node.js environments
3331
- name: Use Node.js ${{ matrix.node-version }}
3432
uses: actions/setup-node@v4
3533
with:
3634
node-version: ${{ matrix.node-version }}
35+
cache: 'pnpm' # Speed up future builds
3736

38-
# Install dependencies with pnpm
3937
- name: Install dependencies
40-
run: pnpm i
38+
run: pnpm install
4139

42-
# Generate the search index tree
4340
- name: Index pages
4441
run: pnpm run gensearch
4542

46-
# Regenerate the search index tree, build the project, and suppress Jekyll
4743
- name: Build
4844
run: |
4945
pnpm run build
5046
touch ./dist/.nojekyll
5147
52-
# Push to your pages repo
5348
- name: Push to pages repo
5449
uses: JamesIves/github-pages-deploy-action@v4
5550
with:

0 commit comments

Comments
 (0)