Skip to content

Instantly share code, notes, and snippets.

@robatwilliams
Created December 17, 2012 12:48
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 robatwilliams/4318053 to your computer and use it in GitHub Desktop.
Save robatwilliams/4318053 to your computer and use it in GitHub Desktop.
Get the username part of the SVN repository url. Doesn't echo anything unless there is one.
# e.g from svn+ssh://username@myrepo.internal
svn info | grep URL: | cut -d / -f 3 | cut -d @ -s -f 1
# output: username
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment