[misc] 03/03: generalise this special casing
Mattia Rizzolo
mattia at debian.org
Sun Mar 11 14:59:05 UTC 2018
This is an automated email from the git hooks/post-receive script.
mattia pushed a commit to branch master
in repository misc.
commit b4b3e8c921c6b237bebd7f94342f2fd638ee8934
Author: Mattia Rizzolo <mattia at debian.org>
Date: Sun Mar 11 15:58:19 2018 +0100
generalise this special casing
Signed-off-by: Mattia Rizzolo <mattia at debian.org>
---
rblib/yamlfiles.py | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/rblib/yamlfiles.py b/rblib/yamlfiles.py
index 5edaa41..9ed8c9c 100644
--- a/rblib/yamlfiles.py
+++ b/rblib/yamlfiles.py
@@ -34,9 +34,12 @@ def write_out(notes):
out += "%s:\n" % pkg
try:
ver = values['version']
- if ver in ('3.6e-1', '4.2e-4') or \
- pkg == 'cdebconf-entropy':
- out += " version: '%s'\n" % ver
+ if isinstance(ver, str):
+ try:
+ if float(ver) != ver:
+ out += " version: '%s'\n" % ver
+ except ValueError:
+ out += " version: %s\n" % ver
else:
out += " version: %s\n" % ver
except KeyError:
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/misc.git
More information about the Reproducible-commits
mailing list