Skip to content

Commit 2f7ed88

Browse files
committed
Fix some minor issues
1 parent 1881d66 commit 2f7ed88

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

bin/v-update-sys-hestia-git

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ download_file() {
6060

6161
if [ ! -f "$ARCHIVE_DIR/$filename" ]; then
6262
[ "$HESTIA_DEBUG" ] && >&2 echo DEBUG: wget $url -q $dstopt --show-progress --progress=bar:force --limit-rate=3m
63-
wget $url -q $dstopt --show-progress --progress=bar:force --limit-rate=3m
63+
wget $url -q $dstopt --show-progress --progress=bar:force --limit-rate=3m
6464
if [ $? -ne 0 ]; then
6565
>&2 echo "[!] Archive $ARCHIVE_DIR/$filename is corrupted and exit script";
6666
rm -f $ARCHIVE_DIR/$filename
@@ -96,9 +96,9 @@ get_branch_file() {
9696

9797
# Set compiling directory
9898
BUILD_DIR='/tmp/hestiacp-src'
99-
INSTALL_DIR='/usr/local/hestia'
99+
INSTALL_DIR='/tmp/hestia-src'
100100
SRC_DIR="$(cd "$(dirname "$0")/.." && pwd)"
101-
ARCHIVE_DIR="$SRC_DIR/src/archive/"
101+
ARCHIVE_DIR="/tmp/hestia-src/archive/"
102102
architecture="$(arch)"
103103
if [ $architecture == 'aarch64' ]; then
104104
BUILD_ARCH='arm64'
@@ -212,7 +212,8 @@ if [ -z "$branch" ]; then
212212
exit
213213
fi
214214
REPO="$fork/hestiacp"
215-
215+
# Forward slashes in branchname are replaced with dashes to match foldername in github archive.
216+
branch_dash=$(echo "$branch" |sed 's/\//-/g');
216217

217218
#----------------------------------------------------------#
218219
# Action #
@@ -252,7 +253,8 @@ fi
252253
GIT_REP='https://raw.githubusercontent.com/'$REPO'/'$branch'/src/deb'
253254

254255
# Generate Links for sourcecode
255-
HESTIA_ARCHIVE_LINK='https://github.com/'$REPO'/'$branch'/archive/'$branch'.tar.gz'
256+
HESTIA_ARCHIVE_LINK='https://github.com/'$REPO'/archive/'$branch'.tar.gz'
257+
echo $HESTIA_ARCHIVE_LINK
256258

257259
echo "Building Hestia Control Panel package..."
258260

@@ -280,7 +282,7 @@ HESTIA_ARCHIVE_LINK='https://github.com/'$REPO'/'$branch'/archive/'$branch'.tar.
280282
elif [ -d $SRC_DIR ]; then
281283
download_file $HESTIA_ARCHIVE_LINK '-' 'fresh' | tar xz
282284
fi
283-
285+
284286
mkdir -p $BUILD_DIR_HESTIA/usr/local/hestia
285287

286288
# Move needed directories

0 commit comments

Comments
 (0)