File tree Expand file tree Collapse file tree 2 files changed +13
-17
lines changed
Expand file tree Collapse file tree 2 files changed +13
-17
lines changed Original file line number Diff line number Diff line change @@ -57,21 +57,13 @@ jobs:
5757 python-version : ' 3.10'
5858 cache : " poetry"
5959 - run : poetry install
60- - name : Semantic release
61- run : |
62- pip install python-semantic-release==7.34.6
63- git config --global user.name "github-actions"
64- git config --global user.email "github-actions[bot]@users.noreply.github.com"
65- semantic-release changelog
66- semantic-release version
67- env :
68- GH_TOKEN : ${{secrets.GH_REPO_TOKEN}}
69- - name : Create GitHub Release
70- run : |
71- semantic-release publish --skip-build
72- env :
73- GH_TOKEN : ${{secrets.GH_REPO_TOKEN}}
74- - name : Build package
75- run : poetry build
60+ - name : Python Semantic Release
61+ id : release
62+ uses :
python-semantic-release/[email protected] 63+ with :
64+ github_token : ${{ secrets.GH_REPO_TOKEN }}
7665 - name : Publish to PyPI
77- uses : pypa/gh-action-pypi-publish@release/v1
66+ uses : pypa/gh-action-pypi-publish@release/v1
67+ if : steps.release.outputs.released == 'true'
68+ with :
69+ print-hash : true
Original file line number Diff line number Diff line change @@ -40,6 +40,10 @@ build_command = "poetry build"
4040major_on_zero = true
4141tag_format = " v{version}"
4242
43+ [tool .semantic_release .publish ]
44+ dist_glob_patterns = [" dist/*" ]
45+ upload_to_vcs_release = true
46+
4347[tool .semantic_release .branches .main ]
4448match = " (main|master)"
4549
You can’t perform that action at this time.
0 commit comments