class Git::Remote::Parser
Constants
- REGEXP
- VERSION
Public Instance Methods
parse(remote_uri)
click to toggle source
# File lib/git/remote/parser.rb, line 40 def parse(remote_uri) if matched = remote_uri.match(REGEXP) Result.new( matched[:protocol], matched[:username] && matched[:username].delete("@".freeze), matched[:host], matched[:owner], matched[:repo], File.join("https://#{matched[:host]}", matched[:owner],matched[:repo]), ) end end