clean hugo install script
parent
e548e54338
commit
a04f0cb2d9
|
@ -39,32 +39,55 @@ root_command() {
|
||||||
local server=${args[--server]:-$BACKUP_SERVER}
|
local server=${args[--server]:-$BACKUP_SERVER}
|
||||||
server=${server:-$s_server}
|
server=${server:-$s_server}
|
||||||
|
|
||||||
local host=${args[--host]:-$s_host}
|
local hostname=${args[--hostname]:-$s_hostname}
|
||||||
if [[ $host ]]; then host="-H $host"; fi
|
hostname=${hostname:-$s_host}
|
||||||
|
hostname=${hostname:-$HOSTNAME}
|
||||||
|
|
||||||
local backup_dir=${args[--backup_dir]:-$BACKUP_DIR}
|
local backup_dir=${args[--backup_dir]:-$BACKUP_DIR}
|
||||||
backup_dir=${backup_dir:-$s_backup_dir}
|
backup_dir=${backup_dir:-$s_backup_dir}
|
||||||
backup_dir=${backup_dir:-"/backup"}
|
backup_dir=${backup_dir:-"/backup"}
|
||||||
|
|
||||||
|
local smount=${args[--source_mount]:-$BACKUP_SOURCE_MOUNT}
|
||||||
|
smount=${smount:-$s_source_mount}
|
||||||
|
|
||||||
|
echo smount: $smount $s_source_mount
|
||||||
|
|
||||||
|
|
||||||
|
local tmount=${args[--target_mount]:-$BACKUP_TARGET_MOUNT}
|
||||||
|
tmount=${tmount:-$s_target_mount}
|
||||||
|
|
||||||
|
echo tmount: $tmount $s_target_mount
|
||||||
|
|
||||||
local source="${args[source]:-$s_source}"
|
local source="${args[source]:-$s_source}"
|
||||||
|
source="${source:-$s_source_path}"
|
||||||
source=$(echo "${source:-$PWD}" | tr -s /)
|
source=$(echo "${source:-$PWD}" | tr -s /)
|
||||||
|
|
||||||
|
echo yaml source $s_source_path $s_source_mount
|
||||||
|
echo source $source
|
||||||
|
|
||||||
|
echo target $s_target
|
||||||
|
|
||||||
|
echo target path $s_target_path
|
||||||
|
|
||||||
local target=${args[target]:-$s_target}
|
local target=${args[target]:-$s_target}
|
||||||
target="$(echo $target | tr -s /)"
|
target=${target:-$s_target_path}
|
||||||
if [[ ${args[--dir]:-$s_dir} ]]; then
|
target=${target:-$(echo "${source}" | tr -s / | sed -e "s#^[.]##")}
|
||||||
target="${target}$(echo $source | tr -s / | sed -e "s#^[.]##")"
|
target="$(echo "${target}" | tr -s /)"
|
||||||
fi
|
echo "target> $target"
|
||||||
if [[ $(isAbsPath $target) ]]; then
|
if [[ ${tmount} ]]; then
|
||||||
echo absolute target directory
|
target="${tmount}${target}"
|
||||||
else
|
else
|
||||||
target="/${s_host:-$HOSTNAME}/${target}"
|
target="/${hostname}${target}"
|
||||||
if [[ $server ]]; then
|
|
||||||
target="rest:${server}${target}"
|
|
||||||
else
|
|
||||||
target=${backup_dir}${target}
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [[ $server ]]; then
|
||||||
|
target="rest:${server}${target}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ $smount ]]; then
|
||||||
|
setpath="--set-path ${source}"
|
||||||
|
source=${smount}${source}
|
||||||
|
fi
|
||||||
|
|
||||||
local exclude=${args[--exclude_file]:-$BACKUP_EXCLUDE}
|
local exclude=${args[--exclude_file]:-$BACKUP_EXCLUDE}
|
||||||
exclude=${exclude:-$s_exclude}
|
exclude=${exclude:-$s_exclude}
|
||||||
|
@ -95,10 +118,12 @@ root_command() {
|
||||||
# local ssh="--remote-schema \"ssh -C %s /home/sysadmin/.local/bin/rdiff-backup --server\""
|
# local ssh="--remote-schema \"ssh -C %s /home/sysadmin/.local/bin/rdiff-backup --server\""
|
||||||
|
|
||||||
#cmd="$sudo rdiff-backup $options $exclude $ssh ${suser}${shost}$source ${tuser}${thost}$target"
|
#cmd="$sudo rdiff-backup $options $exclude $ssh ${suser}${shost}$source ${tuser}${thost}$target"
|
||||||
|
|
||||||
|
|
||||||
local sudo=""
|
local sudo=""
|
||||||
local pcmd="${sudo} ${password} ${bin} -r ${target}"
|
local pcmd="${sudo} ${password} ${bin} -r ${target}"
|
||||||
|
|
||||||
local cmd="${pcmd} ${host} backup ${source} ${exclude}"
|
local cmd="${pcmd} -H ${hostname} ${setpath} backup ${source} ${exclude}"
|
||||||
|
|
||||||
if [[ ${args[--init]} ]]; then cmd="${pcmd} init"; fi
|
if [[ ${args[--init]} ]]; then cmd="${pcmd} init"; fi
|
||||||
if [[ ${args[--snap]} ]]; then cmd="${pcmd} snapshots"; fi
|
if [[ ${args[--snap]} ]]; then cmd="${pcmd} snapshots"; fi
|
||||||
|
@ -188,7 +213,7 @@ dbackup_usage() {
|
||||||
|
|
||||||
# :flag.usage
|
# :flag.usage
|
||||||
echo " --view-path PATH"
|
echo " --view-path PATH"
|
||||||
printf " set custom mount path for viewing of snapshot, --view not required if set\n"
|
printf " set custom mount point path for viewing of snapshot, --view not required if\n set\n"
|
||||||
echo
|
echo
|
||||||
|
|
||||||
# :flag.usage
|
# :flag.usage
|
||||||
|
@ -294,6 +319,11 @@ dbackup_usage() {
|
||||||
echo " BACKUP_DIR"
|
echo " BACKUP_DIR"
|
||||||
printf " Backup Directory\n"
|
printf " Backup Directory\n"
|
||||||
echo
|
echo
|
||||||
|
|
||||||
|
# :environment_variable.usage
|
||||||
|
echo " BACKUP_MOUNT_POINT"
|
||||||
|
printf " mount point of source if mounted external to host\n"
|
||||||
|
echo
|
||||||
# :command.usage_examples
|
# :command.usage_examples
|
||||||
printf "Examples:\n"
|
printf "Examples:\n"
|
||||||
|
|
||||||
|
|
|
@ -15,6 +15,8 @@ environment_variables:
|
||||||
help: URL of Restic rest server
|
help: URL of Restic rest server
|
||||||
- name: BACKUP_DIR
|
- name: BACKUP_DIR
|
||||||
help: Backup Directory
|
help: Backup Directory
|
||||||
|
- name: BACKUP_MOUNT_POINT
|
||||||
|
help: mount point of source if mounted external to host
|
||||||
|
|
||||||
args:
|
args:
|
||||||
- name: source
|
- name: source
|
||||||
|
@ -41,7 +43,7 @@ flags:
|
||||||
short: -v
|
short: -v
|
||||||
help: mount snapshot for viewing (default is BACKUP_MOUNT or /opt/backup/view)
|
help: mount snapshot for viewing (default is BACKUP_MOUNT or /opt/backup/view)
|
||||||
- long: --view-path
|
- long: --view-path
|
||||||
help: set custom mount path for viewing of snapshot, --view not required if set
|
help: set custom mount point path for viewing of snapshot, --view not required if set
|
||||||
arg: path
|
arg: path
|
||||||
- long: --prune
|
- long: --prune
|
||||||
arg: prune
|
arg: prune
|
||||||
|
|
|
@ -32,32 +32,55 @@ password="RESTIC_PASSWORD=${password}"
|
||||||
local server=${args[--server]:-$BACKUP_SERVER}
|
local server=${args[--server]:-$BACKUP_SERVER}
|
||||||
server=${server:-$s_server}
|
server=${server:-$s_server}
|
||||||
|
|
||||||
local host=${args[--host]:-$s_host}
|
local hostname=${args[--hostname]:-$s_hostname}
|
||||||
if [[ $host ]]; then host="-H $host"; fi
|
hostname=${hostname:-$s_host}
|
||||||
|
hostname=${hostname:-$HOSTNAME}
|
||||||
|
|
||||||
local backup_dir=${args[--backup_dir]:-$BACKUP_DIR}
|
local backup_dir=${args[--backup_dir]:-$BACKUP_DIR}
|
||||||
backup_dir=${backup_dir:-$s_backup_dir}
|
backup_dir=${backup_dir:-$s_backup_dir}
|
||||||
backup_dir=${backup_dir:-"/backup"}
|
backup_dir=${backup_dir:-"/backup"}
|
||||||
|
|
||||||
|
local smount=${args[--source_mount]:-$BACKUP_SOURCE_MOUNT}
|
||||||
|
smount=${smount:-$s_source_mount}
|
||||||
|
|
||||||
|
echo smount: $smount $s_source_mount
|
||||||
|
|
||||||
|
|
||||||
|
local tmount=${args[--target_mount]:-$BACKUP_TARGET_MOUNT}
|
||||||
|
tmount=${tmount:-$s_target_mount}
|
||||||
|
|
||||||
|
echo tmount: $tmount $s_target_mount
|
||||||
|
|
||||||
local source="${args[source]:-$s_source}"
|
local source="${args[source]:-$s_source}"
|
||||||
|
source="${source:-$s_source_path}"
|
||||||
source=$(echo "${source:-$PWD}" | tr -s /)
|
source=$(echo "${source:-$PWD}" | tr -s /)
|
||||||
|
|
||||||
|
echo yaml source $s_source_path $s_source_mount
|
||||||
|
echo source $source
|
||||||
|
|
||||||
|
echo target $s_target
|
||||||
|
|
||||||
|
echo target path $s_target_path
|
||||||
|
|
||||||
local target=${args[target]:-$s_target}
|
local target=${args[target]:-$s_target}
|
||||||
target="$(echo $target | tr -s /)"
|
target=${target:-$s_target_path}
|
||||||
if [[ ${args[--dir]:-$s_dir} ]]; then
|
target=${target:-$(echo "${source}" | tr -s / | sed -e "s#^[.]##")}
|
||||||
target="${target}$(echo $source | tr -s / | sed -e "s#^[.]##")"
|
target="$(echo "${target}" | tr -s /)"
|
||||||
fi
|
echo "target> $target"
|
||||||
if [[ $(isAbsPath $target) ]]; then
|
if [[ ${tmount} ]]; then
|
||||||
echo absolute target directory
|
target="${tmount}${target}"
|
||||||
else
|
else
|
||||||
target="/${s_host:-$HOSTNAME}/${target}"
|
target="/${hostname}${target}"
|
||||||
if [[ $server ]]; then
|
|
||||||
target="rest:${server}${target}"
|
|
||||||
else
|
|
||||||
target=${backup_dir}${target}
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [[ $server ]]; then
|
||||||
|
target="rest:${server}${target}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ $smount ]]; then
|
||||||
|
setpath="--set-path ${source}"
|
||||||
|
source=${smount}${source}
|
||||||
|
fi
|
||||||
|
|
||||||
local exclude=${args[--exclude_file]:-$BACKUP_EXCLUDE}
|
local exclude=${args[--exclude_file]:-$BACKUP_EXCLUDE}
|
||||||
exclude=${exclude:-$s_exclude}
|
exclude=${exclude:-$s_exclude}
|
||||||
|
@ -88,10 +111,11 @@ echo exclude: $exclude
|
||||||
# local ssh="--remote-schema \"ssh -C %s /home/sysadmin/.local/bin/rdiff-backup --server\""
|
# local ssh="--remote-schema \"ssh -C %s /home/sysadmin/.local/bin/rdiff-backup --server\""
|
||||||
|
|
||||||
#cmd="$sudo rdiff-backup $options $exclude $ssh ${suser}${shost}$source ${tuser}${thost}$target"
|
#cmd="$sudo rdiff-backup $options $exclude $ssh ${suser}${shost}$source ${tuser}${thost}$target"
|
||||||
|
|
||||||
local sudo=""
|
local sudo=""
|
||||||
local pcmd="${sudo} ${password} ${bin} -r ${target}"
|
local pcmd="${sudo} ${password} ${bin} -r ${target}"
|
||||||
|
|
||||||
local cmd="${pcmd} ${host} backup ${source} ${exclude}"
|
local cmd="${pcmd} -H ${hostname} ${setpath} backup ${source} ${exclude}"
|
||||||
|
|
||||||
if [[ ${args[--init]} ]]; then cmd="${pcmd} init"; fi
|
if [[ ${args[--init]} ]]; then cmd="${pcmd} init"; fi
|
||||||
if [[ ${args[--snap]} ]]; then cmd="${pcmd} snapshots"; fi
|
if [[ ${args[--snap]} ]]; then cmd="${pcmd} snapshots"; fi
|
||||||
|
|
|
@ -1,32 +1,32 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
hugo_install () {
|
hugo_install () {
|
||||||
# inspried from this forum post https://discourse.gohugo.io/t/script-to-install-latest-hugo-release-on-macos-and-ubuntu/14774/10
|
# inspried from this forum post https://discourse.gohugo.io/t/script-to-install-latest-hugo-release-on-macos-and-ubuntu/14774/10
|
||||||
# if you have run into github api anonymous access limits which happens during debugging/dev then add user and token here or sourced from a separate file
|
# if you have run into github api anonymous access limits which happens during debugging/dev then add user and token here or sourced from a separate file
|
||||||
# . ~/githubapitoken
|
# . ~/githubapitoken
|
||||||
#GITHUB_USER=""
|
#GITHUB_USER=""
|
||||||
#GITHUB_TOKEN=""
|
#GITHUB_TOKEN=""
|
||||||
|
|
||||||
if [ "$GITHUB_TOKEN" != "" ]; then
|
if [ "$GITHUB_TOKEN" != "" ]; then
|
||||||
echo using access token with script
|
echo using access token with script
|
||||||
echo $GITHUB_USER $GITHUB_TOKEN
|
echo $GITHUB_USER $GITHUB_TOKEN
|
||||||
fi
|
fi
|
||||||
|
|
||||||
EXTENDED=false
|
EXTENDED=false
|
||||||
FORCE=false
|
FORCE=false
|
||||||
EFILE=""
|
EFILE=""
|
||||||
|
|
||||||
|
|
||||||
# options
|
# options
|
||||||
# e - download and install the extended version
|
# e - download and install the extended version
|
||||||
# c - use 'hugoe' as the install command for extended version otherwise 'hugo' will launch extended version
|
# c - use 'hugoe' as the install command for extended version otherwise 'hugo' will launch extended version
|
||||||
# f - force download/overwrite of same version
|
# f - force download/overwrite of same version
|
||||||
|
|
||||||
declare OPTION
|
declare OPTION
|
||||||
declare OPTARG
|
declare OPTARG
|
||||||
declare OPTIND
|
declare OPTIND
|
||||||
|
|
||||||
while getopts 'ecf' OPTION; do
|
while getopts 'ecf' OPTION; do
|
||||||
case "$OPTION" in
|
case "$OPTION" in
|
||||||
e)
|
e)
|
||||||
echo "installing extended hugo"
|
echo "installing extended hugo"
|
||||||
|
@ -43,90 +43,90 @@ while getopts 'ecf' OPTION; do
|
||||||
FORCE=true
|
FORCE=true
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
|
||||||
shift $(( OPTIND - 1 ))
|
shift $(( OPTIND - 1 ))
|
||||||
|
|
||||||
DEFAULT_BIN_DIR="/usr/local/bin"
|
DEFAULT_BIN_DIR="/usr/local/bin"
|
||||||
# Single optional argument is directory in which to install hugo
|
# Single optional argument is directory in which to install hugo
|
||||||
BIN_DIR=${1:-"$DEFAULT_BIN_DIR"}
|
BIN_DIR=${1:-"$DEFAULT_BIN_DIR"}
|
||||||
|
|
||||||
BIN_PATH="$(which hugo$EFILE)"
|
BIN_PATH="$(which hugo$EFILE)"
|
||||||
declare -A ARCHES
|
declare -A ARCHES
|
||||||
ARCHES=( ["arm64"]="ARM64" ["aarch64"]="ARM64" ["x86_64"]="64bit" ["arm32"]="ARM" ["armhf"]="ARM" )
|
ARCHES=( ["arm64"]="ARM64" ["aarch64"]="ARM64" ["x86_64"]="64bit" ["arm32"]="ARM" ["armhf"]="ARM" )
|
||||||
ARCH=$(arch)
|
ARCH=$(arch)
|
||||||
|
|
||||||
if [ -z "${ARCHES[$ARCH]}" ]; then
|
if [ -z "${ARCHES[$ARCH]}" ]; then
|
||||||
echo Your machine kernel architecture $ARCH is not supported by this script, aborting
|
echo Your machine kernel architecture $ARCH is not supported by this script, aborting
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
INSTALLED="$(hugo$EFILE version 2>/dev/null | cut -d'v' -f2 | cut -c 1-6)"
|
INSTALLED="$(hugo$EFILE version 2>/dev/null | cut -d'v' -f2 | cut -c 1-6)"
|
||||||
CUR_VERSION=${INSTALLED:-"None"}
|
CUR_VERSION=${INSTALLED:-"None"}
|
||||||
echo $(curl -u $GITHUB_USER:$GITHUB_TOKEN -s https://api.github.com/repos/gohugoio/hugo/releases/latest | grep tag_name)
|
echo $(curl -u $GITHUB_USER:$GITHUB_TOKEN -s https://api.github.com/repos/gohugoio/hugo/releases/latest | grep tag_name)
|
||||||
NEW_VERSION="$(curl -u $GITHUB_USER:$GITHUB_TOKEN -s https://api.github.com/repos/gohugoio/hugo/releases/latest \
|
NEW_VERSION="$(curl -u $GITHUB_USER:$GITHUB_TOKEN -s https://api.github.com/repos/gohugoio/hugo/releases/latest \
|
||||||
| grep tag_name \
|
| grep tag_name \
|
||||||
| cut -d'v' -f2 | cut -c 1-6)"
|
| cut -d'v' -f2 | cut -c 1-6)"
|
||||||
|
|
||||||
echo "Hugo `[ $EXTENDED == true ] && echo "Extended"`: Current Version : $CUR_VERSION => New Version: $NEW_VERSION"
|
echo "Hugo `[ $EXTENDED == true ] && echo "Extended"`: Current Version : $CUR_VERSION => New Version: $NEW_VERSION"
|
||||||
|
|
||||||
if [ -z "$NEW_VERSION" ]; then
|
if [ -z "$NEW_VERSION" ]; then
|
||||||
echo Unable to retrieve new version number - Likely you have reached github anonymous limit
|
echo Unable to retrieve new version number - Likely you have reached github anonymous limit
|
||||||
echo set environment variable `$GITHUB_USER` and `$GITHUB_TOKEN` and try again
|
echo set environment variable `$GITHUB_USER` and `$GITHUB_TOKEN` and try again
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
[[ $NEW_VERSION = $CUR_VERSION ]] && [[ $FORCE = false ]] && echo Latest version already installed at $BIN_PATH && return 0
|
[[ $NEW_VERSION = $CUR_VERSION ]] && [[ $FORCE = false ]] && echo Latest version already installed at $BIN_PATH && return 0
|
||||||
|
|
||||||
pushd /tmp/ > /dev/null
|
pushd /tmp/ > /dev/null
|
||||||
|
|
||||||
URL=$(curl -u $GITHUB_USER:$GITHUB_TOKEN -s https://api.github.com/repos/gohugoio/hugo/releases/latest \
|
URL=$(curl -u $GITHUB_USER:$GITHUB_TOKEN -s https://api.github.com/repos/gohugoio/hugo/releases/latest \
|
||||||
| grep "browser_download_url.*hugo.*._Linux-${ARCHES[$ARCH]}\.tar\.gz" \
|
| grep "browser_download_url.*hugo.*._Linux-${ARCHES[$ARCH]}\.tar\.gz" \
|
||||||
| \
|
| \
|
||||||
if [ $EXTENDED = true ]; then
|
if [ $EXTENDED = true ]; then
|
||||||
grep "_extended"
|
grep "_extended"
|
||||||
else
|
else
|
||||||
grep -v "_extended"
|
grep -v "_extended"
|
||||||
fi \
|
fi \
|
||||||
| cut -d ":" -f 2,3 \
|
| cut -d ":" -f 2,3 \
|
||||||
| tr -d \" \
|
| tr -d \" \
|
||||||
)
|
)
|
||||||
|
|
||||||
echo $URL
|
echo $URL
|
||||||
|
|
||||||
echo "Installing version $NEW_VERSION `[ $EXTENDED == true ] && echo "Extended"` "
|
echo "Installing version $NEW_VERSION `[ $EXTENDED == true ] && echo "Extended"` "
|
||||||
echo "This machine's architecture is $ARCH"
|
echo "This machine's architecture is $ARCH"
|
||||||
echo "Downloading Tarball $URL"
|
echo "Downloading Tarball $URL"
|
||||||
|
|
||||||
wget --user=-u $GITHUB_USER --password=$GITHUB_TOKEN -q $URL
|
wget --user=-u $GITHUB_USER --password=$GITHUB_TOKEN -q $URL
|
||||||
|
|
||||||
TARBALL=$(basename $URL)
|
TARBALL=$(basename $URL)
|
||||||
# TARBALL="$(find . -name "*Linux-${ARCHES[$ARCH]}.tar.gz" 2>/dev/null)"
|
# TARBALL="$(find . -name "*Linux-${ARCHES[$ARCH]}.tar.gz" 2>/dev/null)"
|
||||||
echo Expanding Tarball, $TARBALL
|
echo Expanding Tarball, $TARBALL
|
||||||
tar -xzf $TARBALL hugo
|
tar -xzf $TARBALL hugo
|
||||||
|
|
||||||
chmod +x hugo
|
chmod +x hugo
|
||||||
|
|
||||||
if [ -w $BIN_DIR ]; then
|
if [ -w $BIN_DIR ]; then
|
||||||
echo "Installing hugo to $BIN_DIR"
|
echo "Installing hugo to $BIN_DIR"
|
||||||
mv hugo -f $BIN_DIR/hugo$EFILE
|
mv hugo -f $BIN_DIR/hugo$EFILE
|
||||||
else
|
else
|
||||||
echo "installing hugo to $BIN_DIR (sudo)"
|
echo "installing hugo to $BIN_DIR (sudo)"
|
||||||
sudo mv -f hugo $BIN_DIR/hugo$EFILE
|
sudo mv -f hugo $BIN_DIR/hugo$EFILE
|
||||||
fi
|
fi
|
||||||
|
|
||||||
rm $TARBALL
|
rm $TARBALL
|
||||||
|
|
||||||
popd > /dev/null
|
popd > /dev/null
|
||||||
|
|
||||||
echo Installing hugo `[ $EXTENDED == true ] && echo "extended"` as hugo$EFILE
|
echo Installing hugo `[ $EXTENDED == true ] && echo "extended"` as hugo$EFILE
|
||||||
|
|
||||||
BIN_PATH="$(which hugo$EFILE)"
|
BIN_PATH="$(which hugo$EFILE)"
|
||||||
|
|
||||||
if [ -z "$BIN_PATH" ]; then
|
if [ -z "$BIN_PATH" ]; then
|
||||||
printf "WARNING: Installed Hugo Binary in $BIN_DIR is not in your environment path\nPATH=$PATH\n"
|
printf "WARNING: Installed Hugo Binary in $BIN_DIR is not in your environment path\nPATH=$PATH\n"
|
||||||
else
|
else
|
||||||
if [ "$BIN_DIR/hugo$EFILE" != "$BIN_PATH" ]; then
|
if [ "$BIN_DIR/hugo$EFILE" != "$BIN_PATH" ]; then
|
||||||
echo "WARNING: Just installed Hugo binary hugo$EFILE to, $BIN_DIR , conflicts with existing Hugo in $BIN_PATH"
|
echo "WARNING: Just installed Hugo binary hugo$EFILE to, $BIN_DIR , conflicts with existing Hugo in $BIN_PATH"
|
||||||
echo "add $BIN_DIR to path and delete $BIN_PATH"
|
echo "add $BIN_DIR to path and delete $BIN_PATH"
|
||||||
|
@ -134,6 +134,6 @@ else
|
||||||
echo "--- Installation Confirmation ---"
|
echo "--- Installation Confirmation ---"
|
||||||
printf "New Hugo binary version at $BIN_PATH is\n $($BIN_PATH version)\n"
|
printf "New Hugo binary version at $BIN_PATH is\n $($BIN_PATH version)\n"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Reference in New Issue