fix(git): always set origin name when cloning (#622)

* fix(git): force origin name

* Revert "fix(git): honor clone.defaultRemoteName. Fixes #602"

This reverts commit 5af93806aa.
This commit is contained in:
Sean Baildon 2023-03-05 13:09:15 +00:00 committed by GitHub
parent 1407565713
commit 53be2c0ee1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -196,9 +196,7 @@ end
---@param repo string
function M.get_origin(repo)
local config = M.get_config(repo)
local remote = config["clone.defaultRemoteName"] or "origin"
return config["remote." .. remote .. ".url"] or config["remote.origin.url"]
return M.get_config(repo)["remote.origin.url"]
end
---@param repo string

View File

@ -75,6 +75,8 @@ M.clone = {
args[#args + 1] = "--recurse-submodules"
end
args[#args + 1] = "--origin=origin"
args[#args + 1] = "--progress"
if self.plugin.branch then