rust cli app for managing sites blocked via the hosts file
Switch branches/tags
Nothing to show
Clone or download
cgag Some refactorings based on reddit code review.
Avoid intermediate vector in gen_pass.
No need to own every string in gen_pass.
Avoid pointless clone of the initial state.
Latest commit e657a7c Sep 20, 2015
Type Name Latest commit message Commit time
Failed to load latest commit information.
src Some refactorings based on reddit code review. Sep 20, 2015
.gitignore ignore core dump Aug 18, 2015
Cargo.lock update cargo.lock Sep 17, 2015
Cargo.toml bump version after bug fix Sep 17, 2015
LICENSE Add a license (AGPL) Sep 17, 2015 Fix weird "to read go read" in readme Sep 18, 2015

Simple terminal interface for blocking websites via the /etc/hosts file.

Hostblock demo

When you unblock or a remove a domain you'll be asked to enter a mildly annoying random passphrase to give you a chance to reconsider if you really want to go read reddit.

Must be run as sudo as it needs to write to /etc/hosts.


  • i - add a new domain
  • j/k - down, up
  • J/K - goto bottom, goto top
  • d - delete selected
  • space - toggle whether or not selected domain is blocked
  • q - Quit current mode, quits app if in normal mode.
  • h - View help.


Linux x86_64 binary

If you're on linux on an x86_64 processor you can download a binary release here:

The binary is fully statically linked against musl-libc, so it should work on any distro.

Building from source

You'll need to have rustc and cargo installed, you can download them here: Note that cargo is bundled with rust.

- clone repo
- run `cargo build --release`
- sudo ./target/release/hostblock

You should probably move the binary to somewhere on your path.