Skip to content

Restore /etc/hosts each time you remove sites from it (macOS)

Notifications You must be signed in to change notification settings

agentcooper/hosts-cop

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Hosts cop

/etc/hosts file is pretty useful for blocking websites (guide). Once you learn how to do it, it is also easy to unblock them.

Hosts cop will restore /etc/hosts file to the previous version each time you try to remove blocked sites from it.

notification

Adding sites to /etc/hosts will not trigger a notification.

For macOS.

Install

git clone https://github.com/agentcooper/hosts-cop
sudo ./hosts-cop/start

Stop

# from hosts-cop directory
sudo ./stop

Why sudo?

Script needs to run from /Library/LaunchDaemons/ to be able to write to /etc/hosts.

About

Restore /etc/hosts each time you remove sites from it (macOS)

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages