This commit is contained in:
Vokhmin Alexey V 2013-04-11 16:07:29 +04:00
parent 73bb177764
commit cb00f301ba
1 changed files with 2 additions and 2 deletions

View File

@ -8,8 +8,8 @@ module GitHelper
url = node.url(treeish).gsub(/.git$/, '')
if url =~ /^git:/
url.gsub!(/^git/, 'http')
else
str = /git@.*:.*/.match(url)[0].gsub(/^git@/, '')
elsif str = /git@.*:.*/.match(url)
str = str[0].gsub(/^git@/, '')
domen = str.gsub(/:.*/, '')
owner = str.gsub(/^#{domen}:/, '').gsub(/\/.*/, '')
project = str.gsub(/.*\//, '')