tvl-depot/tools/website-blocker
William Carroll 75595b0126 Parse and serialize rules.json
TL;DR:
- Write FromJSON instances to decode rules.json file
- Prefer Text to String and use the OverloadedStrings language extension
- Read /etc/hosts and append the serialized rules.json to the end

Notes:
- I can remove some of the FromJSON instances and use GHC Generics to define
  them for me.

TODO:
- Define the systemd timer unit for this to run
- Ensure script can run with root privileges
2020-03-29 18:49:45 +01:00
..
.envrc Experiment with user /etc/hosts 2020-03-29 00:01:51 +00:00
hosts Experiment with user /etc/hosts 2020-03-29 00:01:51 +00:00
Main.hs Parse and serialize rules.json 2020-03-29 18:49:45 +01:00
rules.json Parse and serialize rules.json 2020-03-29 18:49:45 +01:00
shell.nix Parse and serialize rules.json 2020-03-29 18:49:45 +01:00
Spec.hs Parse and serialize rules.json 2020-03-29 18:49:45 +01:00