peritus / bumpversion

Version-bump your software with a single command
https://pypi.python.org/pypi/bumpversion
MIT License
1.5k stars 148 forks source link

Is it possible to achieve CalVer using bumpversion #130

Open rach opened 8 years ago

rach commented 8 years ago

I've been using bumpversion on most of my project and I like it. Some other projects that I'm working on is using Calendar versioning, Is it outside the scope of bumpversion of supporting it? Currently I don't know a way to customize bumpversion to have Calver working, let me know if I wrong. Thanks a lot.

lgiordani commented 8 years ago

Hi @rach, I have some code which is actually bringing date-based versions into bumpversion. I have a pending PR and some other code which depends on it in my fork. Take a look at the functions branch here https://github.com/lgiordani/bumpversion/tree/functions. I hope we'll merge it soon.

However, if you just want to imitate the Ubuntu schema or similar, you may have a {major} part which starts with 2016 and is incremented like any other version number, and a {minor} which comes from a list of values (for Ubuntu the list is [04,10], but you may use what you want).

Does it solve your problem? Let me know

rach commented 8 years ago

Thanks a lot for the quick answer. Glad to see that you are considering Calver. in bumpversion. Your branch seem to answer my problem and being able to control the format is perfect. I'm not in the rush so I will for it to be merged, it was a question that I was asking myself as I was considering bringing bumpversion in an existing project which use Calver. I will try your branch version and see if I hit any bug.

lgiordani commented 8 years ago

@peritus do you see any problems in merging #119?

guettli commented 3 years ago

This project support CalVer: https://pypi.org/project/bumpver/

lgiordani commented 3 years ago

Hi @guettli thanks for the link. I ended up wirting a tool inspired by bumpversion that supports it as well https://pypi.org/project/punch.py/ :joy_cat: