mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-22 00:16:15 -04:00
bin: Simplify cd to install dir
This commit is contained in:
parent
2f76066d95
commit
335705e03d
5 changed files with 5 additions and 30 deletions
|
@ -7,12 +7,7 @@ fatal() { error "$@"; exit 1; }
|
||||||
is_cmd() { command -v "$@" >/dev/null 2>&1; }
|
is_cmd() { command -v "$@" >/dev/null 2>&1; }
|
||||||
|
|
||||||
# Move to the folder where ep-lite is installed
|
# Move to the folder where ep-lite is installed
|
||||||
cd "$(dirname "$0")"
|
cd "$(dirname "$0")"/..
|
||||||
|
|
||||||
# Was this script started in the bin folder? if yes move out
|
|
||||||
if [ -d "../bin" ]; then
|
|
||||||
cd "../"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Is wget installed?
|
# Is wget installed?
|
||||||
is_cmd wget || fatal "Please install wget"
|
is_cmd wget || fatal "Please install wget"
|
||||||
|
|
|
@ -1,12 +1,7 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
# Move to the folder where ep-lite is installed
|
# Move to the folder where ep-lite is installed
|
||||||
cd "$(dirname "$0")"
|
cd "$(dirname "$0")"/..
|
||||||
|
|
||||||
# Was this script started in the bin folder? if yes move out
|
|
||||||
if [ -d "../bin" ]; then
|
|
||||||
cd "../"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Prepare the environment
|
# Prepare the environment
|
||||||
bin/installDeps.sh || exit 1
|
bin/installDeps.sh || exit 1
|
||||||
|
|
|
@ -45,12 +45,7 @@ require_minimal_version() {
|
||||||
}
|
}
|
||||||
|
|
||||||
# Move to the folder where ep-lite is installed
|
# Move to the folder where ep-lite is installed
|
||||||
cd "$(dirname "$0")"
|
cd "$(dirname "$0")"/..
|
||||||
|
|
||||||
# Was this script started in the bin folder? if yes move out
|
|
||||||
if [ -d "../bin" ]; then
|
|
||||||
cd "../"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Is node installed?
|
# Is node installed?
|
||||||
# Not checking io.js, default installation creates a symbolic link to node
|
# Not checking io.js, default installation creates a symbolic link to node
|
||||||
|
|
|
@ -6,12 +6,7 @@ error() { log "ERROR: $@" >&2; }
|
||||||
fatal() { error "$@"; exit 1; }
|
fatal() { error "$@"; exit 1; }
|
||||||
|
|
||||||
# Move to the folder where ep-lite is installed
|
# Move to the folder where ep-lite is installed
|
||||||
cd "$(dirname "$0")"
|
cd "$(dirname "$0")"/..
|
||||||
|
|
||||||
# Was this script started in the bin folder? if yes move out
|
|
||||||
if [ -d "../bin" ]; then
|
|
||||||
cd "../"
|
|
||||||
fi
|
|
||||||
|
|
||||||
ignoreRoot=0
|
ignoreRoot=0
|
||||||
for ARG in "$@"
|
for ARG in "$@"
|
||||||
|
|
|
@ -25,12 +25,7 @@ LAST_EMAIL_SEND=0
|
||||||
LOG="$1"
|
LOG="$1"
|
||||||
|
|
||||||
# Move to the folder where ep-lite is installed
|
# Move to the folder where ep-lite is installed
|
||||||
cd "$(dirname "$0")"
|
cd "$(dirname "$0")"/..
|
||||||
|
|
||||||
# Was this script started in the bin folder? if yes move out
|
|
||||||
if [ -d "../bin" ]; then
|
|
||||||
cd "../"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Check if a logfile parameter is set
|
# Check if a logfile parameter is set
|
||||||
[ -n "${LOG}" ] || fatal "Set a logfile as the first parameter"
|
[ -n "${LOG}" ] || fatal "Set a logfile as the first parameter"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue