aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorTrygve Laugstøl <trygvis@inamo.no>2013-10-27 23:30:49 +0100
committerTrygve Laugstøl <trygvis@inamo.no>2013-10-27 23:30:49 +0100
commite694d9024cddf4dd54efd828927e3fd5e70b6c3a (patch)
treedcefc5f39fc837736b9822b7446d2b6eb4e6f802 /lib
parent38d7ffca0b591694c17509d20c8bf55606e60536 (diff)
downloadapp.sh-e694d9024cddf4dd54efd828927e3fd5e70b6c3a.tar.gz
app.sh-e694d9024cddf4dd54efd828927e3fd5e70b6c3a.tar.bz2
app.sh-e694d9024cddf4dd54efd828927e3fd5e70b6c3a.tar.xz
app.sh-e694d9024cddf4dd54efd828927e3fd5e70b6c3a.zip
o Removing all old code (X files).
o Making sure APPSH_HOME is 1) exported and, 2) always prepended to $PATH. o More documentation on what a zip file actually looks like and how to create hooks.
Diffstat (limited to 'lib')
-rwxr-xr-xlib/common8
-rw-r--r--lib/header2
2 files changed, 8 insertions, 2 deletions
diff --git a/lib/common b/lib/common
index b52da43..369f0be 100755
--- a/lib/common
+++ b/lib/common
@@ -289,11 +289,17 @@ find_resolver() {
}
#####################################################################
+# Values
+
+key_expr="[a-zA-Z][-_a-zA-Z0-9]*"
+
+#####################################################################
# Common init
# Add the app-* apps to PATH. They're added last to allow the user to
# overload their implementations.
-PATH=$PATH:$APPSH_HOME/bin:$APPSH_HOME/libexec
+# Ideally we should parse the path here and remove duplicates.
+PATH=$APPSH_HOME:$APPSH_HOME/bin:$APPSH_HOME/libexec:$PATH
# Make sure that $HOME is present to prevent unbound errors
HOME=${HOME:-}
diff --git a/lib/header b/lib/header
index 805e06e..876750f 100644
--- a/lib/header
+++ b/lib/header
@@ -3,6 +3,6 @@
set -e
set -u
-APPSH_HOME=$(cd $(dirname "$0")/.. && pwd)
+export APPSH_HOME=$(cd $(dirname "$0")/.. && pwd)
. $APPSH_HOME/lib/common