Add --always parameter to git describe
This commit is contained in:
parent
7987b25f66
commit
4d36fa0c0e
2 changed files with 4 additions and 4 deletions
|
@ -3,7 +3,7 @@
|
|||
Simple python script using GitPython library to generate debian
|
||||
changelog file from git commit history. Each existing tags is
|
||||
considered as a release version and current working version is
|
||||
numbered using ''git describe --tags'' command.
|
||||
numbered using ''git describe --always --tags'' command.
|
||||
|
||||
# Installation
|
||||
|
||||
|
@ -51,7 +51,7 @@ optional arguments:
|
|||
-n PACKAGE_NAME, --package-name PACKAGE_NAME
|
||||
Package name
|
||||
-V VERSION, --version VERSION
|
||||
Currrent version (default: autodetected using git describe --tags)
|
||||
Currrent version (default: autodetected using git describe --always --tags)
|
||||
--version-suffix VERSION_SUFFIX
|
||||
Suffix for autodetected version
|
||||
-c CODE_NAME, --code-name CODE_NAME
|
||||
|
|
4
gitdch
4
gitdch
|
@ -79,7 +79,7 @@ parser.add_argument(
|
|||
'--version',
|
||||
type=str,
|
||||
dest='version',
|
||||
help='Currrent version (default: autodetected using git describe --tags)'
|
||||
help='Currrent version (default: autodetected using git describe --always --tags)'
|
||||
)
|
||||
|
||||
parser.add_argument(
|
||||
|
@ -176,7 +176,7 @@ def add_version():
|
|||
|
||||
tag = None
|
||||
version_commit = None
|
||||
version = options.version or clean_deb_version(repo.git.describe('--tags'))
|
||||
version = options.version or clean_deb_version(repo.git.describe('--always', '--tags'))
|
||||
messages = []
|
||||
for commit in repo.iter_commits():
|
||||
if version_commit is None:
|
||||
|
|
Loading…
Reference in a new issue