From 9486077f1b5c2262b6840e82a9d962e97fcf3d65 Mon Sep 17 00:00:00 2001 From: Pavel Kirilin Date: Wed, 6 Nov 2024 19:57:52 +0100 Subject: [PATCH] Added separate workflow for docs. --- .github/workflows/release.yml | 29 --------------------- .github/workflows/release_docs.yaml | 40 +++++++++++++++++++++++++++++ 2 files changed, 40 insertions(+), 29 deletions(-) create mode 100644 .github/workflows/release_docs.yaml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 95a1089..be8497b 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -6,35 +6,6 @@ on: - released jobs: - deploy_docs: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Setup pnpm - uses: pnpm/action-setup@v2 - - name: Setup Node.js - uses: actions/setup-node@v3 - with: - node-version: 18 - cache: pnpm - - name: Install deps - run: pnpm install - - name: Build - run: pnpm docs:build -d docs_dist - - - name: Setup git - run: | - git config --global lfs.allowincompletepush true - - - name: Deploy - uses: peaceiris/actions-gh-pages@v3 - with: - personal_token: ${{ secrets.PERSONAL_TOKEN }} - external_repository: taskiq-python/taskiq-python.github.io - publish_dir: ./docs_dist - user_name: "github-actions[bot]" - user_email: "github-actions[bot]@users.noreply.github.com" - deploy: runs-on: ubuntu-latest steps: diff --git a/.github/workflows/release_docs.yaml b/.github/workflows/release_docs.yaml new file mode 100644 index 0000000..af56972 --- /dev/null +++ b/.github/workflows/release_docs.yaml @@ -0,0 +1,40 @@ +name: Release docs + +on: + workflow_dispatch: + release: + types: + - released + +permissions: + contents: write + +jobs: + deploy_docs: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Setup pnpm + uses: pnpm/action-setup@v2 + - name: Setup Node.js + uses: actions/setup-node@v3 + with: + node-version: 18 + cache: pnpm + - name: Install deps + run: pnpm install + - name: Build + run: pnpm docs:build -d docs_dist + + - name: Setup git + run: | + git config --global lfs.allowincompletepush true + + - name: Deploy + uses: peaceiris/actions-gh-pages@v3 + with: + personal_token: ${{ secrets.PERSONAL_TOKEN }} + external_repository: taskiq-python/taskiq-python.github.io + publish_dir: ./docs_dist + user_name: "github-actions[bot]" + user_email: "github-actions[bot]@users.noreply.github.com"