From f7a748bfc91daeaf53c8be14d1a8a4fb9c67c417 Mon Sep 17 00:00:00 2001 From: peaceiris <30958501+peaceiris@users.noreply.github.com> Date: Wed, 21 Jul 2021 04:26:18 +0900 Subject: [PATCH] fix: Improve if syntax --- .github/workflows/test.yml | 6 +++--- README.md | 22 +++++++++++----------- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 48cc4973d..f41116496 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -81,19 +81,19 @@ jobs: run: npm run build - name: Remove lint-staged husky - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} run: | npm uninstall lint-staged husky git checkout package-lock.json package.json - name: Setup mdBook - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} uses: peaceiris/actions-mdbook@v1.1.14 with: mdbook-version: '0.4.5' - name: Build site - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} working-directory: ./test_projects/mdbook run: mdbook build diff --git a/README.md b/README.md index 632eb821d..ec8a65739 100644 --- a/README.md +++ b/README.md @@ -162,7 +162,7 @@ jobs: - name: Deploy uses: peaceiris/actions-gh-pages@v3 - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public @@ -672,7 +672,7 @@ jobs: - name: Deploy uses: peaceiris/actions-gh-pages@v3 - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public @@ -722,7 +722,7 @@ jobs: - name: Deploy uses: peaceiris/actions-gh-pages@v3 - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public @@ -777,7 +777,7 @@ jobs: - name: Deploy uses: peaceiris/actions-gh-pages@v3 - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./out @@ -828,7 +828,7 @@ jobs: - name: deploy uses: peaceiris/actions-gh-pages@v3 - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./dist @@ -887,7 +887,7 @@ jobs: - name: Deploy uses: peaceiris/actions-gh-pages@v3 - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./website/build @@ -949,7 +949,7 @@ jobs: - name: Deploy uses: peaceiris/actions-gh-pages@v3 - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./site @@ -990,7 +990,7 @@ jobs: - name: Deploy uses: peaceiris/actions-gh-pages@v3 - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./book @@ -1034,7 +1034,7 @@ jobs: - name: Deploy uses: peaceiris/actions-gh-pages@v3 - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./build/web @@ -1083,7 +1083,7 @@ jobs: - name: Deploy uses: peaceiris/actions-gh-pages@v3 - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./public @@ -1169,7 +1169,7 @@ jobs: - name: Deploy to GitHub Pages uses: peaceiris/actions-gh-pages@v3 - if: github.ref == 'refs/heads/main' + if: ${{ github.ref == 'refs/heads/main' }} with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./Output