File tree Expand file tree Collapse file tree 1 file changed +18
-7
lines changed
Expand file tree Collapse file tree 1 file changed +18
-7
lines changed Original file line number Diff line number Diff line change 77 types :
88 - closed
99 workflow_dispatch :
10+ inputs :
11+ manual_publish :
12+ description : " Run publish and deploy manually"
13+ type : boolean
14+ default : false
15+ required : true
1016
1117jobs :
1218 check-pr-title :
13- if : ${{ github.event_name == 'pull_request_target' && github.event.pull_request.merged == true }}
19+ if : |
20+ github.event_name == 'pull_request_target' &&
21+ github.event.pull_request.merged == true
1422 runs-on : ubuntu-latest
1523 outputs :
1624 is_chore_main_release : ${{ steps.check_title.outputs.is_chore_main_release }}
2634
2735 pypi-publish :
2836 needs : check-pr-title
29- if : ${{ needs.check-pr-title.outputs.is_chore_main_release == 'true' }}
37+ if : |
38+ (github.event_name == 'pull_request_target' && needs.check-pr-title.outputs.is_chore_main_release == 'true') ||
39+ (github.event_name == 'workflow_dispatch' && github.event.inputs.manual_publish == 'true')
3040 name : Upload release to PyPI
3141 runs-on : ubuntu-latest
3242 permissions :
@@ -41,14 +51,15 @@ jobs:
4151 python-version : " 3.12"
4252 cache : true
4353 - name : Publish package distributions to PyPI
44- id : publish
45- run : |
46- pdm publish
47- echo "published=true" >> $GITHUB_OUTPUT
54+ run : pdm publish
55+ - name : Set output
56+ run : echo "published=true" >> $GITHUB_OUTPUT
4857
4958 deploy-docs :
5059 needs : pypi-publish
51- if : ${{ needs.pypi-publish.outputs.published == 'true' }}
60+ if : |
61+ (github.event_name == 'pull_request_target' && needs.pypi-publish.outputs.published == 'true') ||
62+ (github.event_name == 'workflow_dispatch' && github.event.inputs.manual_publish == 'true')
5263 name : Deploy MkDocs
5364 runs-on : ubuntu-latest
5465 permissions :
You can’t perform that action at this time.
0 commit comments