mirror of
https://github.com/tj/git-extras.git
synced 2026-09-10 07:26:17 -04:00
git-delete-submodule: comment the DUMMY prefix and ignore the output of grep -v.
This commit is contained in:
parent
1f605df053
commit
677f570f34
|
|
@ -37,7 +37,8 @@ git add '.gitmodules'
|
|||
git_status_text="$(git submodule status 2>&1)"
|
||||
git_status_exit=$?
|
||||
if [ "$git_status_exit" -eq 0 ] \
|
||||
&& printf '%s' "DUMMY$git_status_text" | grep -v "$NAME"; then
|
||||
&& printf '%s' "DUMMY$git_status_text" | grep -v "$NAME" > /dev/null; then
|
||||
# grep fails when piping in an empty string, so we add a DUMMY prefix
|
||||
|
||||
echo "Successfully deleted $NAME."
|
||||
else
|
||||
|
|
|
|||
Loading…
Reference in a new issue