mirror of
https://github.com/pi-hole/pi-hole.git
synced 2024-11-15 10:43:55 +00:00
Add queryfunc
This commit is contained in:
parent
cb33ef77f7
commit
29b548f07c
1 changed files with 7 additions and 0 deletions
7
pihole
7
pihole
|
@ -62,6 +62,11 @@ function setupLCDFunction {
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function queryFunc {
|
||||||
|
for list in /etc/pihole/list.*;do echo $list;grep '$@' $list;done
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
function chronometerFunc {
|
function chronometerFunc {
|
||||||
shift
|
shift
|
||||||
$SUDO /opt/pihole/chronometer.sh "$@"
|
$SUDO /opt/pihole/chronometer.sh "$@"
|
||||||
|
@ -96,6 +101,7 @@ function helpFunc {
|
||||||
echo "::: -c, chronometer Calculates stats and displays to an LCD"
|
echo "::: -c, chronometer Calculates stats and displays to an LCD"
|
||||||
echo "::: -h, help Show this help dialog"
|
echo "::: -h, help Show this help dialog"
|
||||||
echo "::: -v, version Show current versions"
|
echo "::: -v, version Show current versions"
|
||||||
|
echo "::: -q, query Query the adlists for a specific domain"
|
||||||
echo "::: uninstall Uninstall Pi-Hole from your system :(!"
|
echo "::: uninstall Uninstall Pi-Hole from your system :(!"
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
@ -116,6 +122,7 @@ case "$1" in
|
||||||
"-c" | "chronometer" ) chronometerFunc "$@";;
|
"-c" | "chronometer" ) chronometerFunc "$@";;
|
||||||
"-h" | "help" ) helpFunc;;
|
"-h" | "help" ) helpFunc;;
|
||||||
"-v" | "version" ) versionFunc;;
|
"-v" | "version" ) versionFunc;;
|
||||||
|
"-q" | "query" ) queryFunc;;
|
||||||
"uninstall" ) uninstallFunc;;
|
"uninstall" ) uninstallFunc;;
|
||||||
* ) helpFunc;;
|
* ) helpFunc;;
|
||||||
esac
|
esac
|
||||||
|
|
Loading…
Reference in a new issue