rust2rpm: replace hyphens by underscores in version
- fix issue#124
This commit is contained in:
parent
676ad35a1b
commit
2523fd3c14
1 changed files with 2 additions and 2 deletions
|
@ -75,9 +75,9 @@ class CargoSemVer:
|
||||||
version_str = f'{version.major}.{version.minor or 0}' \
|
version_str = f'{version.major}.{version.minor or 0}' \
|
||||||
f'.{version.patch or 0}'
|
f'.{version.patch or 0}'
|
||||||
if version.pre_release:
|
if version.pre_release:
|
||||||
version_str = f'{version_str}{sep}{version.pre_release}'
|
version_str = f'{version_str}{sep}{version.pre_release.replace("-", "_")}'
|
||||||
if version.build:
|
if version.build:
|
||||||
version_str = f'{version_str}+{version.build}'
|
version_str = f'{version_str}+{version.build.replace("-", "_")}'
|
||||||
return version_str
|
return version_str
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
|
|
Loading…
Reference in a new issue