From 5e9c0e9a3fc26cbab2a1c7f68776cd9ace8a42ff Mon Sep 17 00:00:00 2001 From: emmett1 Date: Thu, 3 Jan 2019 17:21:36 +0800 Subject: [PATCH] fix scratch install -d option --- scratch | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scratch b/scratch index e23a4ae..b2184c3 100755 --- a/scratch +++ b/scratch @@ -609,9 +609,9 @@ installpkg() { for ii in ${PKGNAME[@]}; do if [ ! $(getportpath $ii) ]; then echo "Package '$ii' not found." - elif ! isinstalled $ii; then - echo "Package '$ii' not installed." - return 1 + elif isinstalled $ii; then + echo "Package '$ii' already installed." + return 0 else pushd $(getportpath $ii) pkgbuild -i --no-hook ${OPTS[@]}