diff options
author | Lucio Andrés Illanes Albornoz <lucio@lucioillanes.de> | 2021-01-24 18:44:52 +0000 |
---|---|---|
committer | Lucio Andrés Illanes Albornoz <lucio@lucioillanes.de> | 2021-01-24 18:44:52 +0000 |
commit | c0590b19ae944f4017a52bf036490cf8af682a9f (patch) | |
tree | c9d6d713d1f0af17c3b3ac83a9e502280d680b81 /subr.rtl/rtl_fetch.subr | |
parent | 3689626622516dec6f76b9b4dab05a7544ab583d (diff) | |
download | midipix_build-c0590b19ae944f4017a52bf036490cf8af682a9f.tar.bz2 midipix_build-c0590b19ae944f4017a52bf036490cf8af682a9f.tar.xz |
subr.rtl/rtl_fetch.subr:rtlp_fetch_url_git(): correctly pass ${_git_branch:-main} to git-clone(1).
Diffstat (limited to 'subr.rtl/rtl_fetch.subr')
-rw-r--r-- | subr.rtl/rtl_fetch.subr | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/subr.rtl/rtl_fetch.subr b/subr.rtl/rtl_fetch.subr index 6cb49a94..baa10073 100644 --- a/subr.rtl/rtl_fetch.subr +++ b/subr.rtl/rtl_fetch.subr @@ -33,10 +33,10 @@ rtlp_fetch_url_git() { git pull ${_git_args} origin "${_git_branch:-main}") || return 1; (rtl_fileop cd "${_cache_dname}/${_subdir}" &&\ git submodule update) || return 1; - else if git clone ${_git_args} "${_url}" "${_cache_dname}/${_subdir}"; then + else if git clone ${_git_args} -b "${_git_branch:-main}" "${_url}" "${_cache_dname}/${_subdir}"; then _clonefl=1; else for _url_base in ${_mirrors}; do - if git clone ${_git_args} "${_url_base}/${_pkg_name}/${_url##*/}" "${_cache_dname}/${_subdir}"; then + if git clone ${_git_args} -b "${_git_branch:-main}" "${_url_base}/${_pkg_name}/${_url##*/}" "${_cache_dname}/${_subdir}"; then _clonefl=1; break; fi; done; |