Skip to content

Instantly share code, notes, and snippets.

@TheKrush
Created May 23, 2021 23:21
Show Gist options
  • Save TheKrush/2dc3f141ffea026c26b16af5b512b2ae to your computer and use it in GitHub Desktop.
Save TheKrush/2dc3f141ffea026c26b16af5b512b2ae to your computer and use it in GitHub Desktop.
Updates all submodules of current repo to their latest revision, followed by commit and push.
git submodule foreach git reset --hard
git submodule foreach --recursive git checkout
git submodule foreach git pull origin master
git commit -am "Update submodules to latest"
git push
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment