now trailing .git is properly ignored...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2024-11-09 00:50:41 +03:00
parent c2da2b01b4
commit 433faa03ab

View File

@ -93,7 +93,8 @@ lines=()
| sed -n '/\[remote "origin"\]/,/^\s*url/p' \ | sed -n '/\[remote "origin"\]/,/^\s*url/p' \
| grep 'url = ' \ | grep 'url = ' \
| sed \ | sed \
-e 's/\s*url\s*=\s*//') -e 's/\s*url\s*=\s*//' \
-e 's/.git\s*$//')
[ -z $remote ] \ [ -z $remote ] \
&& continue && continue
line="$path=$remote" line="$path=$remote"
@ -103,7 +104,9 @@ lines=()
if [ -e "$LIST" ] ; then if [ -e "$LIST" ] ; then
cat "$LIST" \ cat "$LIST" \
| grep -ve '\(^\s*#\|^\s*$\)' \ | grep -ve '\(^\s*#\|^\s*$\)' \
| sed -e 's/^-//' | sed \
-e 's/^-//' \
-e 's/.git\s*$//'
fi fi
} \ } \
| sort \ | sort \