Support installing repo from URL with non-master branch

Somewhat related to #905 and #685
pull/908/head
Manu [tennox] 2 years ago committed by Pablo Santiago Blum de Aguiar
parent 55da5f7b6f
commit 90f875e02d

@ -1,12 +1,12 @@
function omf.repo.pull -a repo_dir branch
if test -z "$branch"
set branch "master"
end
function __omf.repo.git -V repo_dir
command git -C "$repo_dir" $argv
end
if test -z "$branch"
set branch (__omf.repo.git symbolic-ref -q --short HEAD)
end
set -l remote origin
if test (__omf.repo.git config --get remote.upstream.url)
set remote upstream

Loading…
Cancel
Save