holoviz-dev / nbsite

Build a tested, sphinx-based website from notebooks
https://nbsite.pyviz.org
BSD 3-Clause "New" or "Revised" License
28 stars 13 forks source link

Add utility to extract the release version from a package version string #204

Closed maximlt closed 2 years ago

maximlt commented 2 years ago

The main use case of this utility being to be used in a conf.py file to set the version and release variables. so that the version that shows up in the HTML title isn't the expanded/ugly one we get when a build is made some time after an actual release.

>>> get_release_version("0.13.0a19.post4+g0695e214")
"0.13.0a19"
maximlt commented 2 years ago

@jbednar if this is fine for you I would cute a nbsite dev release and use this utility for building colorcet's docs (and then the other sites).