mirror of
https://github.com/pi-hole/pi-hole
synced 2025-01-03 12:40:56 +00:00
Merge pull request #962 from pi-hole/queryblacklist
Also query blacklist with pihole -q
This commit is contained in:
commit
b6639d9e7e
5
pihole
5
pihole
@ -69,8 +69,9 @@ setupLCDFunction() {
|
|||||||
|
|
||||||
queryFunc() {
|
queryFunc() {
|
||||||
domain="${2}"
|
domain="${2}"
|
||||||
for list in /etc/pihole/list.*; do
|
lists=( /etc/pihole/list.* /etc/pihole/blacklist.txt)
|
||||||
count=$(grep ${domain} $list | wc -l)
|
for list in ${lists[@]}; do
|
||||||
|
count=$(grep -c ${domain} $list)
|
||||||
echo "::: ${list} (${count} results)"
|
echo "::: ${list} (${count} results)"
|
||||||
if [[ ${count} > 0 ]]; then
|
if [[ ${count} > 0 ]]; then
|
||||||
grep ${domain} ${list}
|
grep ${domain} ${list}
|
||||||
|
Loading…
Reference in New Issue
Block a user