Last active
January 8, 2021 12:18
-
-
Save nataliemarleny/62a9b78e3814197f23b8fd1d091e1fa5 to your computer and use it in GitHub Desktop.
Fetch and reset latest changes in multiple repositories
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for f in $(ls); do | |
cd $f && git fetch --prune origin && git reset --hard origin/$main_branch_name && cd -; | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment