diff options
Diffstat (limited to 'libexec')
-rwxr-xr-x | libexec/app-cat-conf | 4 | ||||
-rwxr-xr-x | libexec/app-grep-path | 2 | ||||
-rwxr-xr-x | libexec/app-install-file | 2 | ||||
-rwxr-xr-x | libexec/app-operate | 2 | ||||
-rwxr-xr-x | libexec/app-operator-pid | 9 | ||||
-rwxr-xr-x | libexec/app-resolver-file | 9 | ||||
-rwxr-xr-x | libexec/app-resolver-maven | 2 | ||||
-rwxr-xr-x | libexec/app-run-hook | 2 | ||||
-rwxr-xr-x | libexec/app-set-version | 2 |
9 files changed, 18 insertions, 16 deletions
diff --git a/libexec/app-cat-conf b/libexec/app-cat-conf index 6e2567f..12d3afc 100755 --- a/libexec/app-cat-conf +++ b/libexec/app-cat-conf @@ -3,13 +3,11 @@ set -e set -u -APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) +export APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) . $APPSH_HOME/lib/common # HEADER END -key_expr="[a-zA-Z][_a-zA-Z0-9]*" - files=() arg_files=() declare -a arg_files diff --git a/libexec/app-grep-path b/libexec/app-grep-path index fa6e5e5..bef44cd 100755 --- a/libexec/app-grep-path +++ b/libexec/app-grep-path @@ -3,7 +3,7 @@ set -e set -u -APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) +export APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) . $APPSH_HOME/lib/common # HEADER END diff --git a/libexec/app-install-file b/libexec/app-install-file index db9432b..be445d9 100755 --- a/libexec/app-install-file +++ b/libexec/app-install-file @@ -3,7 +3,7 @@ set -e set -u -APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) +export APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) . $APPSH_HOME/lib/common # HEADER END diff --git a/libexec/app-operate b/libexec/app-operate index 5fa939d..27727c8 100755 --- a/libexec/app-operate +++ b/libexec/app-operate @@ -3,7 +3,7 @@ set -e set -u -APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) +export APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) . $APPSH_HOME/lib/common # HEADER END diff --git a/libexec/app-operator-pid b/libexec/app-operator-pid index 71871de..a3781ee 100755 --- a/libexec/app-operator-pid +++ b/libexec/app-operator-pid @@ -3,7 +3,7 @@ set -e set -u -APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) +export APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) . $APPSH_HOME/lib/common # HEADER END @@ -80,8 +80,6 @@ find_pid_management() { command_start() { launcher=`find_launcher` - set -x - echo pwd=`pwd` pid_management=`find_pid_management` debug "launcher=$launcher" @@ -95,9 +93,10 @@ command_start() { ;; esac + export APPSH_HOME echo "Starting app..." $launcher <&- 1>&- 2>&- & - + PID=$! case "$pid_management" in @@ -205,7 +204,7 @@ then fatal "\$APP_HOME has to be set." fi -pid_file=$APP_HOME/.app/pid +pid_file=$APP_HOME/.app/pid PID= if [ -r $pid_file ] diff --git a/libexec/app-resolver-file b/libexec/app-resolver-file index 5aedf88..2b708e8 100755 --- a/libexec/app-resolver-file +++ b/libexec/app-resolver-file @@ -3,7 +3,7 @@ set -e set -u -APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) +export APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) . $APPSH_HOME/lib/common # HEADER END @@ -31,7 +31,12 @@ init() { local file=${1-} - if [[ ! -r "$file" ]] + if [[ ! $file =~ ^/ ]] + then + fatal "The file's path must be absolute." + fi + + if [[ ! -r $file ]] then fatal "Can't read file: $file" fi diff --git a/libexec/app-resolver-maven b/libexec/app-resolver-maven index 25f7242..419adcc 100755 --- a/libexec/app-resolver-maven +++ b/libexec/app-resolver-maven @@ -3,7 +3,7 @@ set -e set -u -APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) +export APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) . $APPSH_HOME/lib/common # HEADER END diff --git a/libexec/app-run-hook b/libexec/app-run-hook index 9322fe4..a68ff84 100755 --- a/libexec/app-run-hook +++ b/libexec/app-run-hook @@ -3,7 +3,7 @@ set -e set -u -APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) +export APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) . $APPSH_HOME/lib/common # HEADER END diff --git a/libexec/app-set-version b/libexec/app-set-version index 1b7fd16..f8ba31f 100755 --- a/libexec/app-set-version +++ b/libexec/app-set-version @@ -3,7 +3,7 @@ set -e set -u -APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) +export APPSH_HOME=$(cd $(dirname "$0")/.. && pwd) . $APPSH_HOME/lib/common # HEADER END |