File tree Expand file tree Collapse file tree 3 files changed +86
-26
lines changed Expand file tree Collapse file tree 3 files changed +86
-26
lines changed Original file line number Diff line number Diff line change 1+ name : Upload Mplfinance to PyPI
2+
3+ on :
4+ workflow_dispatch :
5+ inputs :
6+ tag :
7+ description : ' version tag to deploy'
8+ required : true
9+ type : string
10+
11+ jobs :
12+ build_and_deploy :
13+ runs-on : ubuntu-latest
14+ steps :
15+ - name : Checkout Repository
16+ uses : actions/checkout@v2
17+ with :
18+ ref : ${{ github.event.inputs.tag }}
19+
20+ - name : Display Coded Version
21+ # run: git show ${{ github.sha }}:src/mplfinance/_version.py
22+ run : egrep 'version_info .*=' src/mplfinance/_version.py
23+
24+ - name : Set up Python
25+ uses : actions/setup-python@v2
26+ with :
27+ python-version : ' 3.x'
28+
29+ - name : Install dependencies
30+ run : |
31+ python -m pip install --upgrade pip
32+ pip install setuptools wheel twine
33+
34+ - name : Build
35+ run : |
36+ python setup.py sdist bdist_wheel
37+ ls -l dist/*
38+
39+ - name : Publish distribution to PyPI
40+ env :
41+ TWINE_USERNAME : __token__
42+ TWINE_PASSWORD : ${{ secrets.PYPI_API_TOKEN }}
43+ run : twine upload dist/*
Original file line number Diff line number Diff line change 1+ name : Upload Mplfinance to TestPyPI
2+
3+ on :
4+ workflow_dispatch :
5+ inputs :
6+ tag :
7+ description : ' version tag to deploy'
8+ required : true
9+ type : string
10+
11+ jobs :
12+ build_and_deploy :
13+ runs-on : ubuntu-latest
14+ steps :
15+ - name : Checkout Repository
16+ uses : actions/checkout@v2
17+ with :
18+ ref : ${{ github.event.inputs.tag }}
19+
20+ - name : Display Coded Version
21+ # run: git show ${{ github.sha }}:src/mplfinance/_version.py
22+ run : egrep 'version_info .*=' src/mplfinance/_version.py
23+
24+ - name : Set up Python
25+ uses : actions/setup-python@v2
26+ with :
27+ python-version : ' 3.x'
28+
29+ - name : Install dependencies
30+ run : |
31+ python -m pip install --upgrade pip
32+ pip install setuptools wheel twine
33+
34+ - name : Build
35+ run : |
36+ python setup.py sdist bdist_wheel
37+ ls -l dist/*
38+
39+ - name : Publish distribution to Test PyPI
40+ env :
41+ TWINE_USERNAME : __token__
42+ TWINE_PASSWORD : ${{ secrets.TEST_PYPI_API_TOKEN }}
43+ run : twine upload --repository-url https://test.pypi.org/legacy/ dist/*
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments