OSDN Git Service

[fix] : Deploy before gh-pages
authorhayao <hayao@fascode.net>
Sat, 23 Oct 2021 06:49:23 +0000 (15:49 +0900)
committerhayao <hayao@fascode.net>
Sat, 23 Oct 2021 06:49:23 +0000 (15:49 +0900)
.github/workflows/hugo.yaml

index 5a22d87..3bec508 100644 (file)
@@ -34,22 +34,6 @@ jobs:
         run: bash ./update-blog.sh --baseURL https://hayao0819.github.io/hayao.fascode.net/blog/
         #run: hugo --minify -D
 
-      - name: Deploy for GitHub Pages
-        uses: peaceiris/actions-gh-pages@v3
-        with:
-          github_token: ${{ secrets.GITHUB_TOKEN }}
-          publish_branch: gh-pages
-          publish_dir: ./
-
-  main-repo:
-    runs-on: ubuntu-latest
-    steps:
-      - name: Checkout
-        uses: actions/checkout@v2
-        with:
-          submodules: true
-          fetch-depth: 0 
-      
       - name: Setup git repogitories
         env:
           GH_PAGES_REPO_DEPLOY_KEY: ${{ secrets.GH_PAGES_REPO_DEPLOY_KEY }}
@@ -59,7 +43,6 @@ jobs:
           git config --global user.email "hayao@fascode.net"
           git config --global user.name "hayao"
           git config remote.origin.url "git@github.com:Hayao0819/hayao0819.github.io.git"
-          git checkout gh-pages
 
       - name: Deploy pages
         env:
@@ -72,3 +55,12 @@ jobs:
             git push origin master
           fi
 
+      - name: Deploy for GitHub Pages
+        uses: peaceiris/actions-gh-pages@v3
+        with:
+          github_token: ${{ secrets.GITHUB_TOKEN }}
+          publish_branch: gh-pages
+          publish_dir: ./
+
+
+