peng-lab / BaSiCPy

MIT License
62 stars 20 forks source link

Feat/release #72

Closed Nicholas-Schaub closed 2 years ago

Nicholas-Schaub commented 2 years ago

This PR adds:

  1. bump2version to handle versioning
  2. A CI pipeline to automatically build and push new versions to PyPi when a new tag is created

The way this should generally work is this:

  1. Create a new branch from main (if it's a bugfix) or dev (if it's a new feature).
  2. Make all changes, open a PR, review and merge.
  3. Once things are test, use bump2version to change the version and auto-tag the commit. Then push the tag to github.

This will trigger the CI pipeline to build the package and push to PyPi.

I included additional information on creating development versus main releases in the README.

yfukai commented 2 years ago

Thanks a lot for this! It's a great tutorial for me to understand how we can manage versions. I found several formatting disagreements with the pre-commit config. Can you try pre-commit run --all to fix those lines? @Nicholas-Schaub

yfukai commented 2 years ago

I was trying to check how it works in my local environment, but found something a bit funny:

One quick fix may be using .bumpversion.cfg instead of setup.cfg...