Last active
December 15, 2016 16:11
-
-
Save bratsche/8d75ab4f79fbef83c3cd848f6ca2ff24 to your computer and use it in GitHub Desktop.
Differentiate between modified and unmodified files
This file contains 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
git ls-files | while read -r line; do | |
s=$(git status -s "$line"); | |
if [ -n "$s" ]; then | |
echo "$s"; | |
else | |
echo " $line"; | |
fi; | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment