anudeepND / whitelist

A simple tool to add commonly white listed domains to your Pi-Hole setup.
MIT License
4.17k stars 283 forks source link

Remove the Commented dividers (#) #226

Closed ghost closed 2 years ago

ghost commented 2 years ago

It would be easy if I can just copy and paste this whole thing straight into the whitelist box, I don't understand why there's comments, now I have to put in text editor and delete each one out. Do you know an easier method to get this list onto my whitelist?

anudeepND commented 2 years ago

I assume you're talking about optional-list.txt. The reason it has comments is that not everyone is going to add all the domains in that file and comments provide a useful information about the domains and services that are affected.

For example, a domain is affecting National Express, UK while booking a journey. People outside the UK are not affected by this domain.

You can remove the comments quickly buy running this command in you terminal :-

curl -sS https://raw.githubusercontent.com/anudeepND/whitelist/master/domains/optional-list.txt | grep -Ev '(#.*$)|(^$)'