diff --git a/.github/workflows/pythonpublish.yml b/.github/workflows/pythonpublish.yml index 21f2f01..49a750c 100644 --- a/.github/workflows/pythonpublish.yml +++ b/.github/workflows/pythonpublish.yml @@ -17,7 +17,12 @@ jobs: run: | python -m pip install --upgrade pip pip install setuptools wheel twine + - name: update setup.py + run: | + TAG=${GITHUB_REF#refs/*/} + sed setup.py -e "s/version=\"0\.0\.0\"/version=\"$TAG\"/" -i - name: Build and publish + if: startsWith(github.ref, 'refs/tags/v') env: TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }} TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }} diff --git a/setup.py b/setup.py index b9556a7..b81af20 100644 --- a/setup.py +++ b/setup.py @@ -12,12 +12,12 @@ author="Fabien MARTY", author_email="fabien.marty@gmail.com", name="jinja2_humanize_extension", - version="0.0.4", + version="0.0.0", license="BSD", packages=find_packages(), install_requires=install_requires, python_requires='>=3.0', - description="a jinja2 extension to access to system environment variables", + description="a jinja2 extension to use humanize library inside jinja2 templates", long_description=long_description, long_description_content_type="text/markdown", url="https://github.com/metwork-framework/jinja2_humanize_extension",