ソースを参照

chore: add surge preview action (#317)

https://github.com/marketplace/actions/surge-pr-preview
偏右 5 年 前
コミット
eadac21c09
1 ファイル変更18 行追加0 行削除
  1. 18 0
      .github/workflows/preview.yml

+ 18 - 0
.github/workflows/preview.yml

@@ -0,0 +1,18 @@
+name: 🔂 Surge PR Preview
+
+on: [push, pull_request]
+
+jobs:
+  preview:
+    runs-on: ubuntu-latest
+    steps:
+      - uses: actions/checkout@v2
+      - uses: afc163/surge-preview@v1
+        with:
+          surge_token: ${{ secrets.SURGE_TOKEN }}
+          github_token: ${{ secrets.GITHUB_TOKEN }}
+          build: |
+            npm install
+            npm run build:site
+            mv dist/default.html dist/index.html
+          dist: site/public