title: Parse a git URL like 'ssh://git@gitlab.org.net:3333/org/repo.git'?
body: <p>How could I easily extract hostname from a git URL like <code>ssh://git@gitlab.org.net:3333/org/repo.git</code></p>
  
  <pre><code>u = urlparse(s)
  </code></pre>
  
  <p>gives me</p>
  
  <pre><code>ParseResult(scheme='ssh', netloc='git@gitlab.org.net:3333', path='/org/repo.git', params='', query='', fragment='')
  </code></pre>
  
  <p>which means that netloc is closest to what I want and this leaves a disappointing amount of work to me.</p>
  
  <p>Should I do</p>
  
  <pre><code>u.netloc.split('@')[1].split(':')[0]
  </code></pre>
  
  <p>or is there a library that handles it better?</p>