We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2b53bb3 commit 66b69e1Copy full SHA for 66b69e1
check_unstaged.sh
@@ -1,9 +1,9 @@
1
#!/usr/bin/env bash
2
set -euo pipefail
3
+
4
FILES=()
5
IFS=$'\n' read -r -d '' -a FILES < <(git ls-files --other --modified --exclude-standard && printf '\0')
-# FILES="$(git ls-files --other --modified --exclude-standard)"
6
-if [[ "$FILES" != "" ]]; then
+if [[ ${#FILES[@]} -gt 0 ]]; then
7
8
echo
9
echo "The following files contain unstaged changes:"
0 commit comments