mirror of
https://github.com/LazyVim/LazyVim.git
synced 2026-07-25 14:01:06 +00:00
fix(lazygit): fix browsing private git hostings
This commit is contained in:
parent
44ed11c4f8
commit
433dfa9e7c
1 changed files with 1 additions and 1 deletions
|
|
@ -166,7 +166,7 @@ function M.browse()
|
||||||
for _, line in ipairs(lines) do
|
for _, line in ipairs(lines) do
|
||||||
local name, url = line:match("(%S+)%s+(%S+)%s+%(fetch%)")
|
local name, url = line:match("(%S+)%s+(%S+)%s+%(fetch%)")
|
||||||
if name and url then
|
if name and url then
|
||||||
if url:find("git@github.com") or url:find("git@bitbucket.org") or url:find("git@gitlab.com") then
|
if url:find("git@") == 1 then
|
||||||
url = url:gsub("git@(%S+):", "https://%1/"):gsub(".git$", "")
|
url = url:gsub("git@(%S+):", "https://%1/"):gsub(".git$", "")
|
||||||
end
|
end
|
||||||
table.insert(remotes, { name = name, url = url })
|
table.insert(remotes, { name = name, url = url })
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue