Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Usage of git tags #29

Open
FlorianWilhelm opened this issue Feb 10, 2017 · 2 comments
Open

Usage of git tags #29

FlorianWilhelm opened this issue Feb 10, 2017 · 2 comments

Comments

@FlorianWilhelm
Copy link

It would be really nice if tags were used in this project so that one could easily see if the current version 0.4.1.0 on PyPI actually refers to which commit and therefore also if a certain bugfix is included or not.

@CamDavidsonPilon
Copy link
Owner

I agree, though I find tag management to be not obvious to me. Can you provide your own workflow, or a workflow you have seen?

@FlorianWilhelm
Copy link
Author

If you are using no tool for this purpose I think the default way is in order to make a new release is:

  • Update the version to the new version number in setup.py, let's call the version X.Y.Z
  • Also update __version___ in __init__.py to X.Y.Z what most tools provide, check numpy, scipy etc.
    import numpy as np; print(np.__version__)
  • Update your readme and changelog files to reflect the new version
  • Run all your unit tests again and check that they work
  • Commit this and call it "Version bump"
  • Create a git tag X.Y.Z
  • Build and submit the package to PyPI, i.e. python setup.py bdist_wheel upload

My personal recommendation is to just use PyScaffold which will provide an automised version scheme during development. When you want to release it's only:

  • Update Readme and Changelog
  • Commit everything
  • Create a git tag
  • Build and submit your package

PyScaffold will handle the rest like setting the version number everywhere.

@CamDavidsonPilon CamDavidsonPilon mentioned this issue Feb 20, 2017
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants