From 756ab95020bb93eafffae53cfeb415aada13e8b3 Mon Sep 17 00:00:00 2001 From: emmett1 Date: Wed, 26 Jul 2017 11:16:55 +0800 Subject: [PATCH] updated --- install.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/install.sh b/install.sh index ce20192..3e35c7f 100755 --- a/install.sh +++ b/install.sh @@ -2,6 +2,7 @@ bindir="/usr/bin" confdir="/etc" +funcdir="/usr/share/scratchpkg" if [ ! -d $bindir ]; then mkdir -pv $bindir @@ -22,3 +23,10 @@ else [ ! -f $confdir/scratchpkg.conf ] && cp -v scratchpkg.conf $confdir || echo "$confdir/scratchpkg.conf exists" [ ! -d $confdir/scratchpkg.conf.d ] && cp -Rv scratchpkg.conf.d $confdir || echo "$confdir/scratchpkg.conf.d exists" fi + +if [ ! -d $funcdir ]; then + mkdir -pv $funcdir + [ ! -f $funcdir/functions ] && cp -v functions $funcdir +else + [ ! -f $funcdir/functions ] && cp -v functions $funcdir || echo "$funcdir/functions exists" +fi