diff options
author | Leah Rowe <leah@libreboot.org> | 2023-10-20 03:29:55 +0100 |
---|---|---|
committer | Leah Rowe <leah@libreboot.org> | 2023-10-20 03:29:55 +0100 |
commit | 4e54a051ef4ae66bae402479cd4ecdc9709e44ca (patch) | |
tree | 2dcb4f5fd6b55b77522d9bd61fb4c1c64919698a /include | |
parent | 8d9aeef3de28bcb908e33b804517bdeacce7be38 (diff) |
another code cleanup
Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'include')
-rwxr-xr-x | include/git.sh | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/include/git.sh b/include/git.sh index 1c458f08..413af4cc 100755 --- a/include/git.sh +++ b/include/git.sh @@ -15,8 +15,7 @@ fetch_project_trees() [ -z "${rev}" ] && err "fetch_project_trees $target: undefined rev" [ -d "src/${project}/${tree}" ] && \ printf "download/%s %s (%s): exists\n" \ - "${project}" "${tree}" "${_target}" 1>&2 && \ - return 1 + "${project}" "${tree}" "${_target}" 1>&2 && return 0 prepare_new_tree } @@ -30,7 +29,7 @@ fetch_from_upstream() fetch_config() { - x_ rm -f "${cfgsdir}/"*/seen + rm -f "${cfgsdir}/"*/seen || err "fetch_config ${cfgsdir}: !rm seen" while true; do eval "$(setvars "" rev tree)" _xm="fetch_config ${project}/${_target}" @@ -50,7 +49,7 @@ load_target_config() . "${cfgsdir}/${1}/target.cfg" || \ err "load_target_config ${cfgsdir}/${1}: cannot load config" - x_ touch "${cfgsdir}/${1}/seen" + touch "${cfgsdir}/${1}/seen" || err "load_config $cfgsdir/$1: !mk seen" } prepare_new_tree() @@ -74,7 +73,7 @@ fetch_project_repo() verify_config clone_project - [ "${depend}" = "" ] || for d in ${depend} ; do + [ -z "${depend}" ] || for d in ${depend} ; do x_ ./update trees -f ${d} done x_ rm -Rf "${tmp_git_dir}" |