Update save_version.py: Added automatic master branch synchronization
This commit is contained in:
@@ -57,11 +57,18 @@ def main():
|
|||||||
branch_name = f"v{new_version}"
|
branch_name = f"v{new_version}"
|
||||||
run_command([git, 'branch', branch_name])
|
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...")
|
print("📦 Generating production bundle...")
|
||||||
run_command(['./export_prod.sh'])
|
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.")
|
print("Verification: check for the .zip file in the root.")
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
|
|||||||
Reference in New Issue
Block a user