mirror of
https://github.com/searxng/searxng.git
synced 2025-07-31 14:33:50 -04:00
[mod] py: don't append "-dirty" to DOCKER_TAG (#5021)
We don't expect tags to have "-dirty", just the GIT_VERSION regardless of how the container is built.
This commit is contained in:
parent
22c6cd4121
commit
ff2e0ea278
@ -69,6 +69,7 @@ def get_git_version():
|
|||||||
# which depended on the git version: '2023.05.06+..' --> '2023.5.6+..'
|
# which depended on the git version: '2023.05.06+..' --> '2023.5.6+..'
|
||||||
git_commit_date_hash = git_commit_date_hash.replace('.0', '.')
|
git_commit_date_hash = git_commit_date_hash.replace('.0', '.')
|
||||||
tag_version = git_version = git_commit_date_hash
|
tag_version = git_version = git_commit_date_hash
|
||||||
|
docker_tag = git_commit_date_hash.replace("+", "-")
|
||||||
|
|
||||||
# add "+dirty" suffix if there are uncommitted changes except searx/settings.yml
|
# add "+dirty" suffix if there are uncommitted changes except searx/settings.yml
|
||||||
try:
|
try:
|
||||||
@ -78,7 +79,7 @@ def get_git_version():
|
|||||||
git_version += "+dirty"
|
git_version += "+dirty"
|
||||||
else:
|
else:
|
||||||
logger.warning('"%s" returns an unexpected return code %i', e.returncode, e.cmd)
|
logger.warning('"%s" returns an unexpected return code %i', e.returncode, e.cmd)
|
||||||
docker_tag = git_version.replace("+", "-")
|
|
||||||
return git_version, tag_version, docker_tag
|
return git_version, tag_version, docker_tag
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user