Skip to content

Commit f03d758

Browse files
committed
update branch deletion order
1 parent 7a60854 commit f03d758

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

scripts/2_synchronize.sh

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,8 @@ main() {
133133

134134
# Check if the last commit SHA is different
135135
if [ "$last_commit_sha" != "$new_commit_sha" ]; then
136-
echo "Commit "${new_commit_sha:0:6}" found for $path_to_folder_to_synchronize_from"
136+
echo "======================================================================
137+
Commit "${new_commit_sha:0:6}" found for $path_to_folder_to_synchronize_from"
137138

138139
# Debug
139140
# echo "will perform the cloning with params
@@ -145,12 +146,13 @@ main() {
145146
# path_to_folder_to_synchronize_to: "$path_to_folder_to_synchronize_to"
146147
# replacement: "${replacements:0:20}...""
147148

148-
# # Delete branch
149-
git push origin --delete auto_fetch
150-
git branch -D auto_fetch
151149

152150
# Create a branch only if it hasn't been created yet
153151
if [ "$branch_created" = false ]; then
152+
# # Delete branch
153+
git push origin --delete auto_fetch
154+
git branch -D auto_fetch
155+
154156
git pull origin fusion_site_ssplab
155157
git checkout -b auto_fetch
156158
git push -u origin auto_fetch
@@ -173,7 +175,8 @@ main() {
173175
git commit -m "Update $path_to_folder_to_synchronize_to based on commit $new_commit_sha made to $path_to_folder_to_synchronize_from"
174176
git push
175177
else
176-
echo "No new commit since ${last_commit_sha:0:6} found for $path_to_folder_to_synchronize_from"
178+
echo "======================================================================
179+
No new commit since ${last_commit_sha:0:6} found for $path_to_folder_to_synchronize_from"
177180
fi
178181
done
179182
}

0 commit comments

Comments
 (0)