summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 20244ea)
raw | patch | inline | side by side (parent: 20244ea)
author | Jeff King <peff@peff.net> | |
Wed, 22 Oct 2008 19:22:53 +0000 (15:22 -0400) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Thu, 23 Oct 2008 01:06:34 +0000 (18:06 -0700) |
Not all greps support "-e", but in this case we can easily convert it to a
single extended regex.
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
single extended regex.
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-submodule.sh | patch | blob | history |
diff --git a/git-submodule.sh b/git-submodule.sh
index 65178ae8e32bb20c65c42eb9668fb0ffec749007..b63e5c30874bfa382c7d6d0ca1942d116930b62a 100755 (executable)
--- a/git-submodule.sh
+++ b/git-submodule.sh
cd_to_toplevel
# Get modified modules cared by user
modules=$(git diff-index $cached --raw $head -- "$@" |
- grep -e '^:160000' -e '^:[0-7]* 160000' |
+ egrep '^:([0-7]* )?160000' |
while read mod_src mod_dst sha1_src sha1_dst status name
do
# Always show modules deleted or type-changed (blob<->module)
test -z "$modules" && return
git diff-index $cached --raw $head -- $modules |
- grep -e '^:160000' -e '^:[0-7]* 160000' |
+ egrep '^:([0-7]* )?160000' |
cut -c2- |
while read mod_src mod_dst sha1_src sha1_dst status name
do