From 24e50bd9cd5d1a8abff6812aa787cf9fc4af2360 Mon Sep 17 00:00:00 2001 From: Hans Dembinski Date: Mon, 12 Feb 2024 17:59:38 +0100 Subject: [PATCH] fix release and doc scripts --- .github/workflows/docs.yml | 9 ++++++--- .github/workflows/{publish.yml => release.yml} | 2 +- 2 files changed, 7 insertions(+), 4 deletions(-) rename .github/workflows/{publish.yml => release.yml} (98%) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 74d1995..77fa971 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -2,8 +2,9 @@ name: Docs on: pull_request: - release: - types: [published] + push: + tags: + - '**' workflow_dispatch: concurrency: @@ -15,6 +16,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 + with: + fetch-depth: 0 # must come after checkout - uses: actions/setup-python@v5 with: @@ -27,7 +30,7 @@ jobs: path: 'doc/_build/html' deploy: - if: github.event_name == 'workflow_dispatch' || github.event_name == 'release' + if: github.event_name == 'workflow_dispatch' || contains(github.event.ref, '/tags/') needs: build # Set permissions to allow deployment to GitHub Pages permissions: diff --git a/.github/workflows/publish.yml b/.github/workflows/release.yml similarity index 98% rename from .github/workflows/publish.yml rename to .github/workflows/release.yml index 10d2dfd..a285f1b 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/release.yml @@ -1,4 +1,4 @@ -name: Publish +name: Release on: push: