diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index 3ffec8c..e2361c4 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -6,7 +6,12 @@ on: jobs: mkdocs: - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 + permissions: + contents: write + concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + steps: - name: Checkout code uses: actions/checkout@v4 @@ -31,8 +36,11 @@ jobs: echo "MKDOCS_VERSION=$(mkdocs --version | cut -d " " -f 3)" >> $GITHUB_ENV echo "SHORT_SHA=`echo ${GITHUB_SHA} | cut -c1-9`" >> $GITHUB_ENV + - run: rm ./.gitignore + - name: Deploy docs uses: peaceiris/actions-gh-pages@v4 + if: github.ref == 'refs/heads/main' with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./site