From bd97b660147609b31020e06ecf552d8473dfb0d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lucio=20Andr=C3=A9s=20Illanes=20Albornoz=20=28arab=2C=20vx?= =?UTF-8?q?p=29?= Date: Fri, 3 Feb 2017 18:07:44 +0100 Subject: build.sh, etc/build.usage, {subr,vars}/*: general cleanup. --- subr/pkg_fetch.subr | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'subr/pkg_fetch.subr') diff --git a/subr/pkg_fetch.subr b/subr/pkg_fetch.subr index beb76e60..f7da99fe 100644 --- a/subr/pkg_fetch.subr +++ b/subr/pkg_fetch.subr @@ -32,20 +32,22 @@ pkgp_fetch_git() { _fg_subdir="${1}"; _fg_url="${2}"; _fg_branch="${3}"; if [ ${ARG_OFFLINE:-0} -eq 0 ]; then if [ -e "${DLCACHEDIR}/${_fg_subdir}" ]; then - cd ${DLCACHEDIR}/${_fg_subdir} &&\ - git pull origin ${_fg_branch:-main} && cd ${OLDPWD}; + build_fileop cd ${DLCACHEDIR}/${_fg_subdir} &&\ + git pull origin ${_fg_branch:-main} &&\ + build_fileop cd ${OLDPWD}; else git clone ${_fg_url} ${DLCACHEDIR}/${_fg_subdir}; if [ -n "${_fg_branch}" -a \ \( -z "${_fg_branch#main}" \) -a \ \( -z "${_fg_branch#master}" \) ]; then - cd ${DLCACHEDIR}/${_fg_subdir} &&\ - git checkout -b ${_fg_branch} && cd ${OLDPWD}; + build_fileop cd ${DLCACHEDIR}/${_fg_subdir} &&\ + git checkout -b ${_fg_branch} &&\ + build_fileop cd ${OLDPWD}; fi; fi; fi; - secure_rm ${_fg_subdir}; - cp -pr ${DLCACHEDIR}/${_fg_subdir} .; + build_fileop rm ${_fg_subdir}; + build_fileop cp ${DLCACHEDIR}/${_fg_subdir} .; }; pkgp_fetch_urls_git() { -- cgit v1.2.3