Skip to content

Instantly share code, notes, and snippets.

@cattaka
Last active November 22, 2015 00:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cattaka/8bf0375fb41cb20ab49c to your computer and use it in GitHub Desktop.
Save cattaka/8bf0375fb41cb20ab49c to your computer and use it in GitHub Desktop.
Collect git url under the directory
#!/bin/sh
echo "name url"
for i in * ; do
if [ -d $i -a -f $i/.git/config ] ; then
url=`grep url $i/.git/config | cut -d "=" -f 2`
splited=`echo $url|sed "s/[@:\/]/\t/g"`
echo $i $url $splited
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment