Skip to content
This repository was archived by the owner on Jan 25, 2022. It is now read-only.

Commit 5156cad

Browse files
committed
Try to fix broken box self-update
1 parent 9ea69ea commit 5156cad

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

commands/self-update

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,23 @@
66
# all the git commands.
77
# This will be exec at the very end ensuring itself wont be changed during the update.
88

9+
#
910
# Don't reference common variables as they may not exist.
11+
#
1012
WPLIB_BOX_SCRIPTS_REPO="https://github.com/wplib/box-scripts"
1113
WPLIB_BOX_CLI_DIR="/opt/box"
12-
WPLIB_BOX_CLI_VERSION_FILE="/opt/box/version"
13-
WPLIB_BOX_CLI_DEBUG_LOG_FILE="/opt/box/log/cli-debug.log"
14+
WPLIB_BOX_LOG_DIR="${WPLIB_BOX_CLI_DIR}/log"
15+
WPLIB_BOX_CLI_DEBUG_LOG_FILE="${WPLIB_BOX_LOG_DIR}/cli-debug.log"
16+
WPLIB_BOX_CLI_VERSION_FILE="${WPLIB_BOX_CLI_DIR}/version"
1417
DEFAULT_VERSION="master"
1518

19+
#
20+
# Delete the next lines after /opt/box/log exists in VM.
21+
#
22+
mkdir -p "${WPLIB_BOX_LOG_DIR}"
23+
touch "${WPLIB_BOX_CLI_DEBUG_LOG_FILE}"
24+
25+
1626
# Determine version to run.
1727
if [ "" != "$1" ] ; then
1828
VERSION="$1"

0 commit comments

Comments
 (0)