summaryrefslogtreecommitdiff
path: root/src/dagpkg
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@lukeshu.com>2017-05-25 14:39:05 -0400
committerLuke Shumaker <lukeshu@lukeshu.com>2017-05-25 17:28:30 -0400
commit6092b9d93df1c3d5170a2b6aa0275aebef18bd37 (patch)
tree55627e026fa7f538f8085f0fb8ed1fffcce4fcbc /src/dagpkg
parentaedbebb0ea3c7b40dda987b43ff21475ef67f423 (diff)
start moving things to use the libremessages exit codes
Diffstat (limited to 'src/dagpkg')
-rwxr-xr-xsrc/dagpkg12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/dagpkg b/src/dagpkg
index f205390..187fab3 100755
--- a/src/dagpkg
+++ b/src/dagpkg
@@ -54,7 +54,7 @@ source_pkgbuild() {
# Source this PKGBUILD, if it doesn't exist, exit
if ! load_PKGBUILD &>/dev/null; then
error "No PKGBUILD in %s" "$PWD"
- exit 1
+ exit $EXIT_FAILURE
fi
# Save resources
@@ -89,9 +89,13 @@ visit_pkgbuild() {
# Detect cycle or already visited package
case "${marks[$name]:-0}" in
- 1) msg2 "cycle found with %s depending on %s" "$prev" "$name"
- exit 1;;
- 2) return;;
+ 1)
+ msg2 "cycle found with %s depending on %s" "$prev" "$name"
+ exit $EXIT_FAILURE
+ ;;
+ 2)
+ return
+ ;;
esac
msg "%s (%s)" "${name}" "${prev}"