Skip to content

Commit 0b8640a

Browse files
authored
🔨 migrate from setup.py to pyproject.toml (#62)
1 parent ceccfca commit 0b8640a

File tree

11 files changed

+186
-203
lines changed

11 files changed

+186
-203
lines changed

.coveragerc

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

setup.cfg renamed to .flake8

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,3 @@
22
ignore = I100,I201,I202,D203,D401,W503,E203,F401,F403,C901,E501
33
exclude = tests
44
max-line-length = 88
5-
6-
[metadata]
7-
license_files =
8-
LICENSE
9-
10-
[bdist_wheel]
11-
universal = true

.github/workflows/publish.yml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,27 +23,31 @@ jobs:
2323
id: compare
2424
run: |
2525
set -e
26-
VERSION=$(awk -F'"' '/__version__/ {print $2}' sqlite3_to_mysql/__version__.py)
26+
VERSION=$(awk -F'"' '/__version__/ {print $2}' sqlite3_to_mysql/__init__.py)
2727
TAG=${GITHUB_REF_NAME#v}
2828
if [[ "$VERSION" != "$TAG" ]]; then
2929
echo "Version in sqlite3_to_mysql/__version__.py ($VERSION) does not match tag ($TAG)"
3030
exit 1
3131
fi
3232
- name: Set up Python
33+
id: setup_python
3334
uses: actions/setup-python@v4
3435
with:
3536
python-version: "3.x"
36-
- name: Install dependencies
37+
- name: Install build dependencies
38+
id: install_build_dependencies
3739
run: |
3840
python3 -m pip install --upgrade pip
39-
pip install setuptools wheel
41+
pip install build setuptools wheel
4042
- name: Build a binary wheel and a source tarball
41-
run: |
42-
python3 setup.py sdist bdist_wheel
43+
id: build
44+
run: python3 build --sdist --wheel --outdir dist/ .
4345
- name: Publish distribution package to Test PyPI
46+
id: publish_test
4447
uses: pypa/gh-action-pypi-publish@release/v1
4548
with:
4649
repository-url: https://test.pypi.org/legacy/
4750
- name: Publish distribution package to PyPI
51+
id: publish
4852
if: startsWith(github.ref, 'refs/tags')
4953
uses: pypa/gh-action-pypi-publish@release/v1

0 commit comments

Comments
 (0)