]> granicus.if.org Git - graphviz/commitdiff
fix: handle --version not being passed to deployment script
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 9 Jan 2021 19:32:12 +0000 (11:32 -0800)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 9 Jan 2021 19:32:12 +0000 (11:32 -0800)
b443b70a828a34c79c71e41af9cb2eab7b950a14 incorrectly did not anticipate neither
the --force nor --version flags being passed to the deployment script.
Unfortunately I failed to notice this because I was testing using --force and
there was no easy way to test the final work flow until merging to master.

There is also no easy way to test this commit before being merged. I have run
pylint, but after that just need to cross my fingers.

Related to #1892.

ci/deploy.py

index 27158ebb1e96f2bf9eca481d2c903e366283f2a0..421e28e8c80fa115f56b27639a5dc3969508cb72 100644 (file)
@@ -114,6 +114,10 @@ def main(args: [str]) -> int:
     gv_version = f.read().strip()
   log.info(f'VERSION == {gv_version}')
 
+  # if we were not passed an explicit version, use the one from the VERSION file
+  if options.version is None:
+    options.version = gv_version
+
   tarball = f'graphviz-{gv_version}.tar.gz'
   if not os.path.exists(tarball):
     log.error(f'source {tarball} not found')