[wiki] [sites] * improve layout since smu * add zerohosts script gathering different lists in one /etc/hosts || Thuban

From: <git_AT_suckless.org>
Date: Sat, 09 Mar 2019 11:35:02 +0100

commit 549ad088003622d19a713066825298a6e9724410
Author: Thuban <thuban_AT_yeuxdelibad.net>
Date: Sat Mar 9 11:34:07 2019 +0100

    * improve layout since smu
    * add zerohosts script gathering different lists in one /etc/hosts

diff --git a/surf.suckless.org/files/adblock-hosts/index.md b/surf.suckless.org/files/adblock-hosts/index.md
index 07ea530c..60eb2576 100644
--- a/surf.suckless.org/files/adblock-hosts/index.md
+++ b/surf.suckless.org/files/adblock-hosts/index.md
_AT_@ -3,25 +3,26 @@ Adblocking using /etc/hosts
 
 Adblocking is a non-trivial task, but there are trivial solutions.
 
-1. Install hosts-gen from http://git.r-36.net/hosts-gen/
+host-gen
+--------
 
- % git clone http://git.r-36.net/hosts-gen
- % cd hosts-gen
- % sudo make install
-
- Make sure all your custom configuration from your current /etc/hosts is
- preserved in a file in /etc/hosts.d. The files have to begin with a
- number, a minus and then the name.
+Install hosts-gen from <http://git.r-36.net/hosts-gen/>
 
- % sudo hosts-gen
+ % git clone http://git.r-36.net/hosts-gen
+ % cd hosts-gen
+ % sudo make install
 
-2. Install the zerohosts script.
+Make sure all your custom configuration from your current /etc/hosts is
+preserved in a file in /etc/hosts.d. The files have to begin with a
+number, a minus and then the name.
 
- # In the above directory.
- % sudo cp examples/gethostszero /bin
- % sudo chmod 775 /bin/gethostszero
- % sudo /bin/gethostszero
- % sudo hosts-gen
+Install the gethostszero script.
+
+ # In the above directory.
+ % sudo cp examples/gethostszero /bin
+ % sudo chmod 775 /bin/gethostszero
+ % sudo /bin/gethostszero
+ % sudo hosts-gen
 
 Now the /etc/hosts with the zero hosts is ready and will be used in any
 further started application.
_AT_@ -30,8 +31,36 @@ The gethostszero file can of course be reused to more easier create the
 /etc/hosts file. A cronjob can be used to update the file and run hosts-gen
 again.
 
-Author
-------
 
-* Christoph Lohmann < 20h (at) r-36 (dot) net >
+* Author : Christoph Lohmann < 20h (at) r-36 (dot) net >
+
+
+zerohosts
+---------
+
+The following script gather well-known and trusted lists from various
+places : [adaway](https://adaway.org/hosts.txt),
+[someonewhocares](https://someonewhocares.org/hosts/zero/hosts),
+[pgl.yoyo](https://pgl.yoyo.org/adservers/serverlist.php?hostformat=hosts&showintro=0&mimetype=plaintext)...
+
+They are written in `/etc/hosts` file to disable DNS resolution.
+
+Get the script from here :
+[zerohosts](https://dev.yeuxdelibad.net/OpenBSD-stuff/zerohosts).
+
+Edit the script to add you own entries if necessary :
+
+ MYHOSTS="
+ 127.0.0.1 localhost
+ ::1 localhost
+ "
+
+Run the script each time you want to update the lists using a cronjob, or
+`/etc/rc.local` :
+
+ /usr/local/sbin/zerohosts &
+
 
+* Main page : <https://yeuxdelibad.net/Logiciel-libre/Code/zerohosts.html>
+* Author : < thuban (at) yeuxdelibad (dot) net > (feel free to suggest
+improvements)
Received on Sat Mar 09 2019 - 11:35:02 CET

This archive was generated by hypermail 2.3.0 : Sat Mar 09 2019 - 11:36:27 CET