$ git flow init -d
$ git flow feature start MY_NEW_FEATURE
...
$ git flow feature publish MY_NEW_FEATURE # optional
...
$ git push origin feature/MY_NEW_FEATURE
...
$ git flow feature finish -F -p -m 'Release 0.0.1' 0.0.1
...
$ git push origin :feature/MY_NEW_FEATURE
Also see the Python packages section at the bottom.
$ git flow release start 0.1.0
$ git flow release publish 0.1.0 # prevents an error message later
...
- Update version strings.
- Run tests.
- Update changelog.
- Install locally.
...
$ git push origin release/0.1.0
$ git flow release finish -F -p -m 'Release 0.1.0' 0.1.0
git flow hotfix start 0.1.1
git flow hotfix publish 0.1.1
- Update version strings.
- Run tests.
- Update changelog.
- Install locally.
git push origin hotfix/0.1.1
git flow hotfix finish -F -p -m 'Release 0.1.1' 0.1.1
git push origin :hotfix/0.1.1
Perform the following steps to update the version number and possibly the classifiers section of a Python
package and upload the latest version to PyPi. Check ~/.pypirc
for settings.
$ pip install --upgrade twine wheel docutils pygments
$ vim setup.py # Update version and classifiers
$ vim package/__init__.py # Update version
Verify that the README will render on PyPi. Fix any errors as PyPi is very picky.
rst2html README.rst >/dev/null
$ python3 setup.py clean
$ python3 setup.py sdist
$ python3 setup.py bdist_wheel --universal
$ twine upload dist/package-0.1.0*