Skip to content

Commit 3ab38d6

Browse files
committed
update release config
1 parent 04ec6f4 commit 3ab38d6

4 files changed

Lines changed: 46 additions & 31 deletions

File tree

.github/workflows/publish.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Publish
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
8+
jobs:
9+
release:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v2
13+
- name: Set up Python
14+
uses: actions/setup-python@v2
15+
with:
16+
python-version: '3.x'
17+
- name: Install dependencies
18+
run: |
19+
python -m pip install --upgrade pip
20+
pip install setuptools wheel twine
21+
- name: Build
22+
run: python setup.py sdist bdist_wheel
23+
- name: Create release
24+
uses: actions/create-release@v1
25+
env:
26+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
27+
with:
28+
tag_name: ${{ github.ref }}
29+
release_name: umapi-client.py ${{ github.ref }}
30+
body_path: .changelog/latest.md
31+
draft: false
32+
prerelease: false
33+
- id: get_version
34+
uses: battila7/get-version-action@v2
35+
- name: Upload release assets
36+
uses: AButler/upload-release-assets@v2.0
37+
with:
38+
files: dist/*
39+
repo-token: ${{ secrets.GITHUB_TOKEN }}
40+
release-tag: ${{ steps.get_version.outputs.version }}
41+
# - name: Publish to PyPI
42+
# env:
43+
# TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
44+
# TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
45+
# run: twine upload dist/*

.github/workflows/python-publish.yml

Lines changed: 0 additions & 31 deletions
This file was deleted.

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# platform artifacts
22
.*
3+
!.github
34
!.travis.yml
45
!.gitignore
56
!.changelog

0 commit comments

Comments
 (0)