Skip to content

Instantly share code, notes, and snippets.

@yelkarama
Created December 9, 2020 19:57
Show Gist options
  • Save yelkarama/9d4875827b9d3953288a608535c70f9c to your computer and use it in GitHub Desktop.
Save yelkarama/9d4875827b9d3953288a608535c70f9c to your computer and use it in GitHub Desktop.
#!/bin/bash
git reset --hard
git submodule foreach --recursive 'git reset HEAD . || :'
git submodule foreach --recursive 'git checkout -- . || :'
git submodule update --init --recursive
git clean -d -f -f -x
git submodule foreach --recursive git clean -d -f -f -x
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment