File tree Expand file tree Collapse file tree 2 files changed +34
-1
lines changed Expand file tree Collapse file tree 2 files changed +34
-1
lines changed Original file line number Diff line number Diff line change
1
+ name : Publish on release
2
+
3
+ on :
4
+ release :
5
+ types : [created]
6
+
7
+ jobs :
8
+ deploy :
9
+ runs-on : ubuntu-latest
10
+
11
+ steps :
12
+ - uses : actions/checkout@v1
13
+ - name : Set up Python
14
+ uses : actions/setup-python@v1
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
21
+ - name : Build
22
+ env :
23
+ VERSION_RAW : ${{ github.ref }}
24
+ # Transform refs/tags/v0.0.2a01 to 0.0.2a01 and inject it into setup.py
25
+ run : |
26
+ export VERSION=`echo $VERSION_RAW | sed -E 's;.*/v(.*)$;\1;'`
27
+ sed -i 's/%VERSION%/'$VERSION'/' setup.py
28
+ python setup.py sdist bdist_wheel
29
+ - name : Publish a Python distribution to PyPI
30
+ uses : pypa/gh-action-pypi-publish@master
31
+ with :
32
+ user : __token__
33
+ password : ${{ secrets.PYPI_TOKEN }}
Original file line number Diff line number Diff line change 5
5
6
6
setuptools .setup (
7
7
name = 'evasdk' ,
8
- version = '0.0.1 ' ,
8
+ version = '%VERSION% ' ,
9
9
description = 'SDK for the Automata Eva robotic arm' ,
10
10
author = 'Automata' ,
11
11
license = 'Apache License 2.0' ,
You can’t perform that action at this time.
0 commit comments