Only continue each commnd if they are successful.
This commit is contained in:
@@ -911,17 +911,17 @@
|
|||||||
fi
|
fi
|
||||||
echo "* Base not specified, using '$base' for '$rcvr'."
|
echo "* Base not specified, using '$base' for '$rcvr'."
|
||||||
fi
|
fi
|
||||||
echo "* Ensuring we are on base branch '$base'."
|
echo "* Ensuring we are on base branch '$base'." &&
|
||||||
git switch "$base"
|
git switch "$base" &&
|
||||||
echo "* Changing pointer for '$rcvr' to '$base'."
|
echo "* Changing pointer for '$rcvr' to '$base'." &&
|
||||||
git branch -f "$rcvr" "$base"
|
git branch -f "$rcvr" "$base" &&
|
||||||
#echo "* Switching to branch '$rcvr'."
|
#echo "* Switching to branch '$rcvr'." &&
|
||||||
#git switch "$rcvr"
|
#git switch "$rcvr" &&
|
||||||
echo "* Forcing push on branch '$rcvr'."
|
echo "* Forcing push on branch '$rcvr'." &&
|
||||||
git push --force --set-upstream origin "$rcvr"
|
git push --force --set-upstream origin "$rcvr" &&
|
||||||
#echo "* Switching back to '$base'."
|
#echo "* Switching back to '$base'." &&
|
||||||
#git switch "$base"
|
#git switch "$base" &&
|
||||||
echo "* Done! Displaying list of remote branches."
|
echo "* Done! Displaying list of remote branches." &&
|
||||||
git ls-remote --heads | sort
|
git ls-remote --heads | sort
|
||||||
}
|
}
|
||||||
alias load-prod="load-branch prod"
|
alias load-prod="load-branch prod"
|
||||||
|
Reference in New Issue
Block a user