From 419a457a3dabd3f4030f86aae8e082b492ec0084 Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Wed, 13 Mar 2019 15:32:52 -0400 Subject: ob-*: Replace exit with return --- diff --git a/src/ob-applypatches.sh b/src/ob-applypatches.sh index 90ccc3d..165c426 100644 --- a/src/ob-applypatches.sh +++ b/src/ob-applypatches.sh @@ -57,8 +57,8 @@ main() { ob_set_text_domain 'opkbuild' - ob_init_package '..' || exit 1 - ob_parse_package_metadata -c '.opkbuild.cache' || exit 1 + ob_init_package '..' || return 1 + ob_parse_package_metadata -c '.opkbuild.cache' || return 1 apply_patches || return 1 diff --git a/src/ob-buildenv.sh b/src/ob-buildenv.sh index 06c7136..3c7cac2 100644 --- a/src/ob-buildenv.sh +++ b/src/ob-buildenv.sh @@ -81,8 +81,8 @@ main() { ob_set_text_domain 'opkbuild' - ob_init_package '..' || exit 1 - ob_parse_package_metadata -c '.opkbuild.cache' || exit 1 + ob_init_package '..' || return 1 + ob_parse_package_metadata -c '.opkbuild.cache' || return 1 ob_info "$(ob_get_msg 'setup_build_env')" diff --git a/src/ob-buildopk.sh b/src/ob-buildopk.sh index 55dfdc9..2e18855 100644 --- a/src/ob-buildopk.sh +++ b/src/ob-buildopk.sh @@ -40,8 +40,8 @@ main() { ob_set_text_domain 'opkbuild' - ob_init_package '..' || exit 1 - ob_parse_package_metadata -c '.opkbuild.cache' || exit 1 + ob_init_package '..' || return 1 + ob_parse_package_metadata -c '.opkbuild.cache' || return 1 printf '2.0\n' >'debian-binary' if [ -n "${OB_DO_SOURCE}" ]; then diff --git a/src/ob-checkbuilddeps.sh b/src/ob-checkbuilddeps.sh index e002029..7cc1fbd 100644 --- a/src/ob-checkbuilddeps.sh +++ b/src/ob-checkbuilddeps.sh @@ -85,8 +85,8 @@ main() { ob_set_text_domain 'opkbuild' - ob_init_package '..' || exit 1 - ob_parse_package_metadata -c '.opkbuild.cache' || exit 1 + ob_init_package '..' || return 1 + ob_parse_package_metadata -c '.opkbuild.cache' || return 1 ob_set_package_substvars '' check_build_deps || return ${?} diff --git a/src/ob-genchanges.sh b/src/ob-genchanges.sh index c591b26..f6685c2 100644 --- a/src/ob-genchanges.sh +++ b/src/ob-genchanges.sh @@ -83,8 +83,8 @@ main() { ob_set_text_domain 'opkbuild' - ob_init_package '..' || exit 1 - ob_parse_package_metadata -c '.opkbuild.cache' || exit 1 + ob_init_package '..' || return 1 + ob_parse_package_metadata -c '.opkbuild.cache' || return 1 if [ -n "${OB_DO_SOURCE}" ]; then changes="${OPK_SOURCE}_${OPK_SOURCE_VERSION}_src_all.changes" diff --git a/src/ob-gencontrol.sh b/src/ob-gencontrol.sh index 79f30d4..7c1e2eb 100644 --- a/src/ob-gencontrol.sh +++ b/src/ob-gencontrol.sh @@ -160,8 +160,8 @@ main() { ob_set_text_domain 'opkbuild' - ob_init_package '..' || exit 1 - ob_parse_package_metadata -c '.opkbuild.cache' || exit 1 + ob_init_package '..' || return 1 + ob_parse_package_metadata -c '.opkbuild.cache' || return 1 if [ -n "${OB_DO_SOURCE}" ]; then gen_control "src-${OPK_SOURCE}" "${OPK_SOURCE_VERSION}" 'src' 'all' \ diff --git a/src/ob-installdocs.sh b/src/ob-installdocs.sh index 292925c..f48134d 100644 --- a/src/ob-installdocs.sh +++ b/src/ob-installdocs.sh @@ -60,8 +60,8 @@ main() { ob_set_text_domain 'opkbuild' - ob_init_package '..' || exit 1 - ob_parse_package_metadata -c '.opkbuild.cache' || exit 1 + ob_init_package '..' || return 1 + ob_parse_package_metadata -c '.opkbuild.cache' || return 1 if ! doc_pkg="$(ob_get_doc_package)"; then ob_error "$(ob_get_msg 'cant_get_doc_pkg')" diff --git a/src/ob-installplatconf.sh b/src/ob-installplatconf.sh index bb6df2c..fd9e607 100644 --- a/src/ob-installplatconf.sh +++ b/src/ob-installplatconf.sh @@ -69,8 +69,8 @@ main() { ob_set_text_domain 'opkbuild' - ob_init_package '..' || exit 1 - ob_parse_package_metadata -c '.opkbuild.cache' || exit 1 + ob_init_package '..' || return 1 + ob_parse_package_metadata -c '.opkbuild.cache' || return 1 copied='false' diff --git a/src/ob-unpacksource.sh b/src/ob-unpacksource.sh index e90c6c0..fab5659 100644 --- a/src/ob-unpacksource.sh +++ b/src/ob-unpacksource.sh @@ -135,8 +135,8 @@ main() { ob_set_text_domain 'opkbuild' - ob_init_package '..' || exit 1 - ob_parse_package_metadata -c '.opkbuild.cache' || exit 1 + ob_init_package '..' || return 1 + ob_parse_package_metadata -c '.opkbuild.cache' || return 1 if [ -d 'src' ]; then ob_info "$(ob_get_msg 'already_unpacked')" -- cgit v0.9.1