]> git.otsuka.systems Git - cotsuka.github.io/commitdiff
use bun in gh action v1.0.0
authorCameron Otsuka <cameron@otsuka.haus>
Thu, 5 Jun 2025 17:35:16 +0000 (10:35 -0700)
committerCameron Otsuka <cameron@otsuka.haus>
Thu, 5 Jun 2025 17:35:16 +0000 (10:35 -0700)
.github/workflows/deploy-to-ghpages.yml

index 065d9c926e38661d1f3acc760b7a387ff646a157..4831fdb2ffd2107e8a6b9adb020a17a5566e3ad2 100644 (file)
@@ -16,20 +16,22 @@ jobs:
     steps:
       - uses: actions/checkout@v4
 
-      - name: Setup Node
-        uses: actions/setup-node@v4
+      - name: Setup Bun
+        uses: oven-sh/setup-bun@v2
         with:
-          node-version-file: 'package.json'
-          check-latest: true
+          bun-version: latest
+          # bun-version-file: 'package.json'
 
-      - name: Persist npm cache
+      - name: Persist Bun cache
         uses: actions/cache@v4
         with:
-          path: ~/.npm
-          key: ${{ runner.os }}-node-${{ hashFiles('**/package.json') }}
+          path: ~/.bun/install/cache
+          key: ${{ runner.os }}-${{ matrix.bun }}-bun-${{ hashFiles('**/bun.lock') }}
+          restore-keys: |
+            ${{ runner.os }}-${{ matrix.bun }}-bun-
 
-      - run: npm install
-      - run: npm run build-ghpages
+      - run: bun install
+      - run: bun run build-ghpages
 
       - name: Deploy
         uses: peaceiris/actions-gh-pages@v4