diff --git a/Documents/bin/find-uncomitted b/Documents/bin/find-uncomitted new file mode 100755 index 0000000000000000000000000000000000000000..3ea78d72d40ecd5858cdb24498794cc744e62787 --- /dev/null +++ b/Documents/bin/find-uncomitted @@ -0,0 +1,10 @@ +#!/bin/sh +set -eu + +# shellcheck disable=SC2044 +for repo in $(find "$HOME/Repositories" -maxdepth 7 -type d -name .git -exec dirname {} \;) +do + [ "$(git -C "$repo" stat | wc -l)" -gt '1' ] || continue + [ "$(git -C "$repo" remote show | wc -l)" -gt 0 ] || continue + echo "$repo" +done