Skip to content

Commit e195358

Browse files
authored
Merge branch 'master' into master
2 parents 70e4f6e + b6fa063 commit e195358

File tree

2 files changed

+62
-4
lines changed

2 files changed

+62
-4
lines changed

.github/release-drafter-config.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
name-template: 'Version $NEXT_PATCH_VERSION🌈'
1+
name-template: 'Version $NEXT_PATCH_VERSION'
22
tag-template: 'v$NEXT_PATCH_VERSION'
33
categories:
4-
- title: '🚀Features'
4+
- title: 'Features'
55
labels:
66
- 'feature'
77
- 'enhancement'
@@ -10,9 +10,9 @@ categories:
1010
- 'fix'
1111
- 'bugfix'
1212
- 'bug'
13-
- title: '🧰Maintenance'
13+
- title: 'Maintenance'
1414
label: 'chore'
15-
change-template: '- $TITLE @$AUTHOR (#$NUMBER)'
15+
change-template: '- $TITLE (#$NUMBER)'
1616
exclude-labels:
1717
- 'skip-changelog'
1818
template: |

.github/workflows/publish-pypi.yml

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
name: Publish Pypi
2+
on:
3+
release:
4+
types: [ published ]
5+
6+
jobs:
7+
pytest:
8+
name: Publish to PyPi
9+
runs-on: ubuntu-latest
10+
env:
11+
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
12+
steps:
13+
- uses: actions/checkout@master
14+
15+
- name: get version from tag
16+
id: get_version
17+
run: |
18+
realversion="${GITHUB_REF/refs\/tags\//}"
19+
realversion="${realversion//v/}"
20+
echo "::set-output name=VERSION::$realversion"
21+
22+
- name: Set the version for publishing
23+
uses: ciiiii/[email protected]
24+
with:
25+
file: "pyproject.toml"
26+
key: "tool.poetry.version"
27+
value: "${{ steps.get_version.outputs.VERSION }}"
28+
29+
- name: Set up Python 3.7
30+
uses: actions/setup-python@v1
31+
with:
32+
python-version: 3.7
33+
34+
- name: Install Poetry
35+
uses: dschep/[email protected]
36+
37+
- name: Cache Poetry virtualenv
38+
uses: actions/cache@v1
39+
id: cache
40+
with:
41+
path: ~/.virtualenvs
42+
key: poetry-${{ hashFiles('**/poetry.lock') }}
43+
restore-keys: |
44+
poetry-${{ hashFiles('**/poetry.lock') }}
45+
46+
- name: Set Poetry config
47+
run: |
48+
poetry config virtualenvs.in-project false
49+
poetry config virtualenvs.path ~/.virtualenvs
50+
51+
- name: Install Dependencies
52+
run: poetry install
53+
if: steps.cache.outputs.cache-hit != 'true'
54+
55+
- name: Publish to PyPI
56+
if: github.event_name == 'release'
57+
run: |
58+
poetry publish -u __token__ -p ${{ secrets.PYPI_TOKEN }} --build

0 commit comments

Comments
 (0)