From f2e9d585f79f757302eaf7417f6e7209bc848352 Mon Sep 17 00:00:00 2001 From: Adam Warner Date: Sun, 16 Jul 2017 13:22:59 +0100 Subject: [PATCH] * Add helptext for `pihole checkout ftl` * Only attempt to install FTL if branch was found * ~~corebranches~~ webbranches (web branches now actually listed) Signed-off-by: Adam Warner --- advanced/Scripts/piholeCheckout.sh | 7 +++---- pihole | 7 ++++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/advanced/Scripts/piholeCheckout.sh b/advanced/Scripts/piholeCheckout.sh index f9add489..b786ba0c 100644 --- a/advanced/Scripts/piholeCheckout.sh +++ b/advanced/Scripts/piholeCheckout.sh @@ -303,12 +303,12 @@ checkout() { fi webbranches=($(get_available_branches "${webInterfaceDir}")) - if [[ "${corebranches[@]}" == *"master"* ]]; then + if [[ "${webbranches[@]}" == *"master"* ]]; then echo -e "${OVER} ${TICK} $str ${INFO} ${#webbranches[@]} branches available for Web Admin" else # Print STDERR output from get_available_branches - echo -e "${OVER} ${CROSS} $str\n\n${corebranches[*]}" + echo -e "${OVER} ${CROSS} $str\n\n${webbranches[*]}" exit 1 fi @@ -329,12 +329,11 @@ checkout() { if check_download_exists "$path"; then echo " ${TICK} Branch ${2} exists" + FTLinstall "${binary}" "${path}" else echo " ${CROSS} Requested branch \"${2}\" is not available" fi - FTLinstall "${binary}" "${path}" - else echo -e " ${INFO} Requested option \"${1}\" is not available" exit 1 diff --git a/pihole b/pihole index 1bd35dbb..8da911d8 100755 --- a/pihole +++ b/pihole @@ -429,15 +429,15 @@ Time: # Enable Pi-hole echo -e " ${INFO} Enabling blocking" local str="Pi-hole Enabled" - + sed -i 's/^#addn-hosts/addn-hosts/' /etc/dnsmasq.d/01-pihole.conf if [[ -e "/etc/pihole/wildcard.list" ]]; then mv "/etc/pihole/wildcard.list" "$wildcardlist" fi fi - + restartDNS - + echo -e "${OVER} ${TICK} ${str}" } @@ -535,6 +535,7 @@ Switch Pi-hole subsystems to a different Github branch Repositories: core [branch] Change the branch of Pi-hole's core subsystem web [branch] Change the branch of Admin Console subsystem + ftl [branch] Change the branch of Pi-hole's FTL subsystem Branches: master Update subsystems to the latest stable release