hc-rs-0.3.7 is not a library.
this is a WIP
whats done
- fetching hosts files
- merging hosts files
- removing duplicate lines
- cli options
- colored output messages
- configuration file
- replace with /etc/hosts(i think this should be done manually though)
building from git source
$ git clone https://github.com/XDream8/hc-rs
$ cd hc-rs
$ cargo build --profile optimized
$ ./target/optimized/hc-rs
usage
creating a hosts file
- pass urls directly to hc-rs
- you can pass as much urls as you want to
removing duplicate lines
use --remove-duplicates(-r) flag to remove duplicate lines from the downloaded content/hosts
removing duplicate lines from a already created hosts file
I added a subcommand just for this purpose
setting output filename
use --output(-o) flag to set output filename
default filename is "hosts"
ignoring fetching errors
use --ignore-errors(-i) flag to ignore fetching errors and don't exit
aliasing in your shell config