File tree Expand file tree Collapse file tree 3 files changed +62
-27
lines changed
Expand file tree Collapse file tree 3 files changed +62
-27
lines changed Original file line number Diff line number Diff line change 1+ name : Publish to PyPI
2+
3+ on :
4+ release :
5+ types : [published]
6+
7+ workflow_dispatch :
8+
9+ jobs :
10+ build_publish :
11+ runs-on : ubuntu-latest
12+ steps :
13+ - name : Checkout code
14+ uses : actions/checkout@v2
15+
16+ - name : Set up Python
17+ uses : actions/setup-python@v2
18+ with :
19+ python-version : ' 3.9'
20+
21+ - name : Install Poetry
22+ run : |
23+ pip install --upgrade pip
24+ curl -sSL https://install.python-poetry.org | python3 -
25+ poetry config virtualenvs.create false
26+ poetry install
27+
28+ - name : Build package
29+ run : poetry build
30+
31+ - name : Publish package to PyPI
32+ env :
33+ POETRY_PYPI_TOKEN_PYPI : ${{ secrets.PYPI_TOKEN }}
34+ run : poetry publish --username __token__ --password $POETRY_PYPI_TOKEN_PYPI
Original file line number Diff line number Diff line change 55 branches :
66 - main
77
8+ # For manual triggers
89 workflow_dispatch :
910
1011jobs :
@@ -40,32 +41,32 @@ jobs:
4041 token : ${{ secrets.CODECOV_TOKEN }}
4142 files : ./coverage.xml
4243
43- build :
44- if : github.actor != 'actions[bot]'
45- runs-on : ubuntu-latest
46-
47- needs : test
48-
49- steps :
50- - name : Checkout code
51- uses : actions/checkout@v2
52- with :
53- ref : ${{ github.head_ref }}
54-
55-
56- - name : Set up Python
57- uses : actions/setup-python@v2
58- with :
59- python-version : ' 3.9'
44+ pre_build :
45+ if : github.actor != 'actions[bot]'
46+ runs-on : ubuntu-latest
47+ needs : test
48+ steps :
49+ - name : Checkout code
50+ uses : actions/checkout@v2
51+ with :
52+ ref : ${{ github.head_ref }}
6053
61- - name : Install Poetry
62- run : |
63- pip install --upgrade pip
64- curl -sSL https://install.python-poetry.org | python3 -
65- poetry config virtualenvs.create false
66- poetry install
54+ - name : Set up Python
55+ uses : actions/setup-python@v2
56+ with :
57+ python-version : ' 3.9'
6758
68- - name : Increment version
69- run : |
70- poetry version patch # params: patch, minor, major
59+ - name : Install Poetry
60+ run : |
61+ pip install --upgrade pip
62+ curl -sSL https://install.python-poetry.org | python3 -
63+ poetry config virtualenvs.create false
64+ poetry install
7165
66+ - name : Increment version
67+ run : |
68+ git config --global user.name 'GitHub Actions'
69+ git config --global user.email '[email protected] ' 70+ git push
71+ git tag -f $(poetry version -s)
72+ git push -f origin --tags
Original file line number Diff line number Diff line change 11[tool .poetry ]
22name = " api-to-dataframe"
3- version = " 0.0.7 "
3+ version = " 0.0.9 "
44description = " A package to convert API responses to pandas dataframe"
55authors = [
" IvanildoBarauna <[email protected] >" ]
66readme = " README.md"
You can’t perform that action at this time.
0 commit comments