File tree Expand file tree Collapse file tree 3 files changed +10
-1
lines changed
Expand file tree Collapse file tree 3 files changed +10
-1
lines changed Original file line number Diff line number Diff line change 22
33## 1.0.0
44
5- - Added tests, CI workflows and hatchling/ trusted publishing
5+ - Added tests, CI workflows and hatchling/ trusted publishing and ` --version ` option
66 [ @jensens , 2025-11-03]
77- Initial porting from https://github.com/rnixx/githelper
88 [ @rnix , 2025-03-03]
Original file line number Diff line number Diff line change @@ -43,6 +43,9 @@ build-backend = "hatchling.build"
4343[tool .hatch .version ]
4444source = " vcs"
4545
46+ [tool .hatch .build .hooks .vcs ]
47+ version-file = " src/mxrepo/_version.py"
48+
4649[tool .hatch .metadata ]
4750allow-direct-references = true
4851
Original file line number Diff line number Diff line change 11from argparse import ArgumentParser
2+ from importlib .metadata import version
23
34import json
45import os
910
1011
1112mainparser = ArgumentParser (description = "Git helper utilities" )
13+ mainparser .add_argument (
14+ "--version" ,
15+ action = "version" ,
16+ version = f"%(prog)s { version ('mxrepo' )} " ,
17+ )
1218subparsers = mainparser .add_subparsers (help = "command" , required = True )
1319
1420
You can’t perform that action at this time.
0 commit comments