Skip to content

Instantly share code, notes, and snippets.

@MarioVilas
Created April 18, 2016 11:25
Show Gist options
  • Save MarioVilas/723ec63ac70ece98a197b48c1081cce2 to your computer and use it in GitHub Desktop.
Save MarioVilas/723ec63ac70ece98a197b48c1081cce2 to your computer and use it in GitHub Desktop.
A simple script so git users can enumerate the repositories they can access. Place it at: ~/git-shell-commands/no-interactive-login
#!/bin/sh
echo
echo 'SSH successfully configured.'
echo 'Now try running:'
for i in *.git
do
printf ' git clone %s@%s:%s\n' $USER $(cat /etc/hostname) $i
done
echo
exit 128
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment