Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
upgrade-zulip-from-git: We may need to fill in a zulip-git-version file.
Alex Vandiver8ae167dc0544
diff --git a/scripts/lib/zulip_tools.py b/scripts/lib/zulip_tools.pyindex 70e1a234e66..b2d879ab5b7 100755--- a/scripts/lib/zulip_tools.py+++ b/scripts/lib/zulip_tools.py@@ -108,6 +108,23 @@ def get_deploy_root() -> str:def parse_version_from(deploy_path: str, merge_base: bool = False) -> str:+ if not os.path.exists(os.path.join(deploy_path, "zulip-git-version")):+ try:+ # Pull this tool from _our_ deploy root, since it may not+ # exist historically, but run it the cwd of the old+ # deploy, so we set up its remote.+ subprocess.check_call(+ [os.path.join(get_deploy_root(), "scripts", "lib", "update-git-upstream")],+ cwd=deploy_path,+ preexec_fn=su_to_zulip,+ )+ subprocess.check_call(+ [os.path.join(deploy_path, "tools", "cache-zulip-git-version")],+ cwd=deploy_path,+ preexec_fn=su_to_zulip,+ )+ except subprocess.CalledProcessError:+ passtry:varname = "ZULIP_MERGE_BASE" if merge_base else "ZULIP_VERSION"return subprocess.check_output(