Skip to content

Commit b32f0b5

Browse files
authored
Merge pull request #389 from jmmshn/patch_wf2
Add Docs to PR WF
2 parents 30f62bd + abbdd4d commit b32f0b5

File tree

2 files changed

+12
-4
lines changed

2 files changed

+12
-4
lines changed

.github/workflows/pytest-docs.yml

+12-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,16 @@
11
name: Build Docs
22

33
on:
4-
[release, workflow_dispatch]
4+
push:
5+
branches:
6+
- main
7+
tags:
8+
- "v*"
9+
pull_request:
10+
branches:
11+
- main
12+
release:
13+
types: [published]
514

615
jobs:
716
build:
@@ -33,8 +42,8 @@ jobs:
3342
run: |
3443
cd docs_rst
3544
make html
36-
- name: Detect changes
37-
if: ${{ !contains(github.ref, 'refs/heads/main') }}
45+
- name: Detect changes on release
46+
if: startsWith(github.head_ref, 'releases/')
3847
id: changes
3948
shell: bash
4049
run: |

.github/workflows/release.yml

-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@ jobs:
3838
run: pip install build
3939

4040
- name: Publish package
41-
if: contains(github.ref, 'refs/heads/main')
4241
uses: pypa/gh-action-pypi-publish@release/v1.5
4342
with:
4443
user: __token__

0 commit comments

Comments
 (0)