Hello. I was hoping to get some feedback if this c...
# general
l
Hello. I was hoping to get some feedback if this change/enhancement makes sense to contribute back to pants. Currently the vcs_version target supports supplying a
tag_regex
which is great as it allows you to have a custom tagging scheme. However you’re unable to supply a value for
git_describe_command
which makes it unable to be directly used if you want said version to be generated only for tags with a specific prefix/suffix (IE 1 repo, multiple versions). For example the repository might have 2 projects. Each wanting to control their own versions using scm tagging. However with the current setup they would need to share a version because the setuptools_scm default is to use
git describe --dirty --tags --long --match '*[0-9]*'
to get the version to parse with
tag_regex
. right now i have a custom plugin based off vcs_version that allows me to specify this. But was wondering if this was something that the larger pants project would want/desire? The change is relatively simple (example patch here) but i also know the vcs_version plugin is intentionally limited so this kind of customization might not be desired.
Any feedback on this? I can an open an issue too. Was following the instructions in the pants docs on contributing 🙂
👀 1
h
Sorry, your original post must have gotten lost in the scrollback
OK, looks reasonable to me! I'd be inclined to accept that patch. It's a pretty thin wrapper around existing functionality in setuptools_scm, and you've done your homework there.
l
awesome! i’ll work on getting a PR prepped