Update version on release
- name: Build docs
working-directory: docs
run: sphinx-build -E -W -b html . _build/html
+ - name: Build Python package
+ run: |
+ pip install --upgrade build twine
+ for file in $(find -not -path "./.*" -not -path "./docs*" \( -name "*.py" -o -name "*.toml" \) ); do
+ sed -i -e "s/0.0.0+auto.0/1.2.3/" $file;
+ done;
+ python -m build
+ twine check dist/*
TWINE_USERNAME: ${{ secrets.pypi_username }}
TWINE_PASSWORD: ${{ secrets.pypi_password }}
run: |
- for file in $(find -not -path "./.*" -not -path "./docs*" -name "*.py"); do
- sed -i -e "s/0.0.0-auto.0/${{github.event.release.tag_name}}/" $file;
+ for file in $(find -not -path "./.*" -not -path "./docs*" \( -name "*.py" -o -name "*.toml" \) ); do
+ sed -i -e "s/0.0.0+auto.0/${{github.event.release.tag_name}}/" $file;
done;
- python setup.py sdist
+ python -m build
twine upload dist/*
#
# SPDX-License-Identifier: MIT
"""Return the current version"""
-VERSION = (1, 0, 0)
-__version__ = ".".join(map(str, VERSION))
+__version__ = VERSION = "0.0.0+auto.0"
"""
-__version__ = "0.0.0-auto.0"
+__version__ = "0.0.0+auto.0"
__repo__ = "https://github.com/adafruit/Adafruit_Blinka.git"
__blinka__ = True