Skip to content

Instantly share code, notes, and snippets.

@NedkoHristov
Created April 7, 2020 10:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save NedkoHristov/d44fd60622978d77846f910d2ddfb0c1 to your computer and use it in GitHub Desktop.
Save NedkoHristov/d44fd60622978d77846f910d2ddfb0c1 to your computer and use it in GitHub Desktop.
Update all git repos in directory
nedko@nedko:~/repo$ find . -name .git -type d | xargs -n1 -P4 -I% git --git-dir=% --work-tree=%/.. pull

-P4 is for working at 4 consecutive repos if needed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment