mirror of
https://github.com/unmojang/meta.git
synced 2025-09-23 11:10:53 -04:00
chore: Use cd ... || exit
in case cd fails
This commit is contained in:
parent
031d271d62
commit
189a7eecc5
2
clone.sh
2
clone.sh
@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
BASEDIR=$(dirname "$0")
|
||||
cd "${BASEDIR}"
|
||||
cd "${BASEDIR}" || exit 1
|
||||
BASEDIR=`pwd`
|
||||
|
||||
source config.sh
|
||||
|
@ -2,7 +2,7 @@
|
||||
echo "Launch args: $@"
|
||||
|
||||
if [ "$1" == "update" ]; then
|
||||
cd /app
|
||||
cd /app || exit 1
|
||||
exec su user -c "bash ./update.sh"
|
||||
elif [ "$1" == "cron" ]; then
|
||||
exec cron -f
|
||||
|
@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
BASEDIR=$(dirname "$0")
|
||||
cd "${BASEDIR}"
|
||||
cd "${BASEDIR}" || exit 1
|
||||
BASEDIR=`pwd`
|
||||
|
||||
source config.sh
|
||||
|
Loading…
x
Reference in New Issue
Block a user