diff options
author | Anthony Sottile <asottile@umich.edu> | 2021-07-05 18:24:23 -0400 |
---|---|---|
committer | Anthony Sottile <asottile@umich.edu> | 2021-07-05 18:30:07 -0400 |
commit | 5fcc293ba268a89ea1535114d36fbdcb73ec3d88 (patch) | |
tree | beb70d3e8d90200aa77ef2ffa88dd5ce29a19f89 /scripts | |
parent | 650aad3a5fb84059b392ad450f760ed08143ae3f (diff) | |
download | docker-py-5fcc293ba268a89ea1535114d36fbdcb73ec3d88.tar.gz |
use python3.6+ constructs
Signed-off-by: Anthony Sottile <asottile@umich.edu>
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/versions.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/versions.py b/scripts/versions.py index 4bdcb74..75e5355 100755 --- a/scripts/versions.py +++ b/scripts/versions.py @@ -52,8 +52,8 @@ class Version(namedtuple('_Version', 'major minor patch stage edition')): return (int(self.major), int(self.minor), int(self.patch)) + stage def __str__(self): - stage = '-{}'.format(self.stage) if self.stage else '' - edition = '-{}'.format(self.edition) if self.edition else '' + stage = f'-{self.stage}' if self.stage else '' + edition = f'-{self.edition}' if self.edition else '' return '.'.join(map(str, self[:3])) + edition + stage |