From 26e8f034a26d6cc23a1d2b55251a7a90dbf3f0a3 Mon Sep 17 00:00:00 2001 From: Daniel Bedeleanu Date: Sun, 12 Apr 2026 21:32:55 +0300 Subject: [PATCH] Update save_version.py: Added automatic master branch synchronization --- scripts/save_version.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/scripts/save_version.py b/scripts/save_version.py index b1b44279..35b413fe 100644 --- a/scripts/save_version.py +++ b/scripts/save_version.py @@ -57,11 +57,18 @@ def main(): branch_name = f"v{new_version}" run_command([git, 'branch', branch_name]) - # 4. Create Production Bundle + # 4. Update master branch + print(f"🔄 Updating 'master' branch to v{new_version}...") + current_branch = run_command([git, 'rev-parse', '--abbrev-ref', 'HEAD']) + run_command([git, 'checkout', 'master']) + run_command([git, 'merge', current_branch]) + run_command([git, 'checkout', current_branch]) + + # 5. Create Production Bundle print("📦 Generating production bundle...") run_command(['./export_prod.sh']) - print(f"Successfully saved version {new_version}, created branch {branch_name}, and generated production ZIP.") + print(f"Successfully saved version {new_version}, created branch {branch_name}, updated 'master', and generated production ZIP.") print("Verification: check for the .zip file in the root.") if __name__ == "__main__":