mirror of
https://github.com/pi-hole/pi-hole.git
synced 2024-12-24 13:50:17 +00:00
Merge branch 'development' into release/v4.0
This commit is contained in:
commit
5b628a4c77
2 changed files with 5 additions and 5 deletions
|
@ -38,14 +38,14 @@ lighttpdConfig=/etc/lighttpd/lighttpd.conf
|
|||
# This is a file used for the colorized output
|
||||
coltable=/opt/pihole/COL_TABLE
|
||||
|
||||
# We store several other folders and
|
||||
# We store several other directories and
|
||||
webInterfaceGitUrl="https://github.com/pi-hole/AdminLTE.git"
|
||||
webInterfaceDir="/var/www/html/admin"
|
||||
piholeGitUrl="https://github.com/pi-hole/pi-hole.git"
|
||||
PI_HOLE_LOCAL_REPO="/etc/.pihole"
|
||||
# These are the names of pi-holes files, stored in an array
|
||||
PI_HOLE_FILES=(chronometer list piholeDebug piholeLogFlush setupLCD update version gravity uninstall webpage)
|
||||
# This folder is where the Pi-hole scripts will be installed
|
||||
# This directory is where the Pi-hole scripts will be installed
|
||||
PI_HOLE_INSTALL_DIR="/opt/pihole"
|
||||
PI_HOLE_CONFIG_DIR="/etc/pihole"
|
||||
useUpdateVars=false
|
||||
|
@ -320,7 +320,7 @@ else
|
|||
fi
|
||||
}
|
||||
|
||||
# A function for checking if a folder is a git repository
|
||||
# A function for checking if a directory is a git repository
|
||||
is_repo() {
|
||||
# Use a named, local variable instead of the vague $1, which is the first argument passed to this function
|
||||
# These local variables should always be lowercase
|
||||
|
@ -335,7 +335,7 @@ is_repo() {
|
|||
if [[ -d "${directory}" ]]; then
|
||||
# move into the directory
|
||||
cd "${directory}"
|
||||
# Use git to check if the folder is a repo
|
||||
# Use git to check if the directory is a repo
|
||||
# git -C is not used here to support git versions older than 1.8.4
|
||||
git status --short &> /dev/null || rc=$?
|
||||
# If the command was not successful,
|
||||
|
|
|
@ -106,7 +106,7 @@ removeNoPurge() {
|
|||
${SUDO} rm -rf /var/www/html/pihole &> /dev/null
|
||||
${SUDO} rm -f /var/www/html/index.lighttpd.orig &> /dev/null
|
||||
|
||||
# If the web directory is empty after removing these files, then the parent html folder can be removed.
|
||||
# If the web directory is empty after removing these files, then the parent html directory can be removed.
|
||||
if [ -d "/var/www/html" ]; then
|
||||
if [[ ! "$(ls -A /var/www/html)" ]]; then
|
||||
${SUDO} rm -rf /var/www/html &> /dev/null
|
||||
|
|
Loading…
Reference in a new issue