Skip to content

Commit 0e19ac0

Browse files
authored
Merge pull request #191 from nicolasbock/pypi
Fix PyPi package
2 parents f088fd2 + dc09c60 commit 0e19ac0

File tree

5 files changed

+19
-18
lines changed

5 files changed

+19
-18
lines changed

.github/workflows/build.yaml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,6 @@ jobs:
1515
fail-fast: true
1616
matrix:
1717
include:
18-
- os: ubuntu-18.04
19-
python-version: 3.6
2018
- os: ubuntu-22.04
2119
python-version: 3.7
2220
- os: ubuntu-22.04
@@ -49,7 +47,7 @@ jobs:
4947
- name: Install tox
5048
run: sudo apt install --yes tox
5149

52-
- name: Test
50+
- name: Build and test
5351
run: tox -e ${{ env.tox_environment }}
5452

5553
- name: Archive test results
@@ -77,3 +75,7 @@ jobs:
7775
- name: Build docs
7876
run: tox -e docs
7977
if: ${{ matrix.python-version == '3.10' }}
78+
79+
- name: Test PyPi Package
80+
run: tox -e pypi
81+
if: ${{ matrix.python-version == '3.10' }}

.github/workflows/publish.yaml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,17 @@ jobs:
1313
name: Publish PyPI Package
1414
steps:
1515
- name: Check out sources
16-
uses: actions/checkout@v2
16+
uses: actions/checkout@v3
1717
with:
1818
fetch-depth: 0
1919
- name: Set up Python
2020
uses: actions/setup-python@v1
2121
with:
22-
python-version: '3.9'
22+
python-version: '3.10'
2323
- name: Publish PyPI Package
2424
env:
2525
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
2626
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
2727
run: |
28-
python setup.py --version
29-
git log --oneline --decorate --color | head -n 20
30-
pip install setuptools wheel twine
31-
rm -rf dist
32-
python setup.py sdist bdist_wheel
33-
twine upload dist/*
28+
tox -e pypi
29+
twine upload .tox/pypi/dist/*

CONTRIBUTING.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Developer Documentation
22
=======================
33

4-
This project supports Python 3.6, 3.7, 3.8, 3.9, and 3.10. Other Python versions
4+
This project supports Python 3.7, 3.8, 3.9, and 3.10. Other Python versions
55
might work as well but are not regularly tested.
66

77
For locally testing changes it is very handy to install `tox` which automates

README.rst

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -124,9 +124,3 @@ The command understands the following command line arguments:
124124
--pull Download latest docker image
125125
--show-options Show currently selected options and defaults
126126
--ccache CCACHE_DIR Path to mount that contains ccache cache
127-
128-
Developer Instructions
129-
----------------------
130-
131-
For more information and how to contribute to this project see the
132-
:doc:`Contributing <contributing>` page.

tox.ini

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,12 @@ commands = bandit --exit-zero --recursive {toxinidir}/ebuildtester {toxinidir}/t
2525

2626
[testenv:pep8]
2727
commands = pycodestyle ebuildtester
28+
29+
[testenv:pypi]
30+
deps =
31+
setuptools
32+
wheel
33+
twine
34+
commands =
35+
python setup.py sdist bdist_wheel --dist-dir {envdir}/dist
36+
twine check --strict {envdir}/dist/*

0 commit comments

Comments
 (0)