From 807c012a969af9c3f59c25a36f0b140586cba4d5 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Wed, 22 Mar 2023 10:42:28 +0100 Subject: gpush/gpick: heed --dry-run more carefully skip saving the state also after branch tracking activity (both local and remote), to make the operation truly read-only (and thus reproducible) - the remaining exception are the PatchSet refs gpick fetches from Gerrit, but this is basically a cache. Change-Id: I8e3f708945ee0e6d33483177b394de90e833edc2 Reviewed-by: Alexandru Croitor --- bin/git_gpush.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/git_gpush.pm b/bin/git_gpush.pm index 2eb2118..9fc7cf7 100644 --- a/bin/git_gpush.pm +++ b/bin/git_gpush.pm @@ -2104,7 +2104,7 @@ sub _source_map_finish_initial() } source_map_finish(); - save_state() if ($sm_changed); + save_state($dry_run) if ($sm_changed); } # Update the target branches of local Changes according to the data @@ -2159,7 +2159,7 @@ sub _update_target_branches($) # The Changes may be printed again later. delete $$_{annotation} foreach (@changed); } - save_state() if ($need_save); + save_state($dry_run) if ($need_save); } ####################### -- cgit v1.2.3