noot
This commit is contained in:
parent
3883292bd6
commit
ec647555b5
2
Makefile
2
Makefile
@ -7,7 +7,7 @@ REPOTOOL_PATH ?= ${HOME}/repo
|
||||
|
||||
all: dist/repotool
|
||||
|
||||
install: dist/repotool shell/zsh/repotool.zsh shell/zsh/repotool.plugin.zsh
|
||||
install: dist/repotool shell/repotool.zsh shell/repotool.plugin.zsh
|
||||
mkdir -p ${REPOTOOL_PATH}/.bin/
|
||||
mkdir -p ${REPOTOOL_PATH}/.shell/
|
||||
install dist/repotool ${REPOTOOL_PATH}/.bin/
|
||||
|
||||
3453
lib/luaunit.lua
Normal file
3453
lib/luaunit.lua
Normal file
File diff suppressed because it is too large
Load Diff
13
src/git.lua
13
src/git.lua
@ -7,9 +7,18 @@ function git.parse_url(url)
|
||||
local domain, path
|
||||
|
||||
-- Check if it's an HTTP(S) URL
|
||||
domain, path = url:match("^https?://[^/]*@?([^/]+)/(.+)%.git$")
|
||||
-- First try without authentication
|
||||
domain, path = url:match("^https?://([^@/]+)/(.+)%.git$")
|
||||
if not domain then
|
||||
domain, path = url:match("^https?://[^/]*@?([^/]+)/(.+)$")
|
||||
domain, path = url:match("^https?://([^@/]+)/(.+)$")
|
||||
end
|
||||
|
||||
-- If that didn't match, try with authentication
|
||||
if not domain then
|
||||
domain, path = url:match("^https?://[^@]+@([^/]+)/(.+)%.git$")
|
||||
end
|
||||
if not domain then
|
||||
domain, path = url:match("^https?://[^@]+@([^/]+)/(.+)$")
|
||||
end
|
||||
|
||||
-- Check if it's an SSH URL (git@host:path or ssh://...)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user