$ unbound-control-setup
$ systemctl enable stubby unbound
$ systemctl start stubby unboundUnbound dumps statistics to syslog every six hours:
| * Write contents to `/etc/modprobe.d/broken-suspend.conf`. |
| autocmd BufNewFile,BufRead *.jobf set diffexpr=DiffJobf() | |
| function DiffJobf() | |
| let expr = "s_[Cfmp]o?[0-9]{4}[a-zA-Z0-9]_FNORD_g" | |
| let opt = "" | |
| if &diffopt =~ "icase" | |
| let opt = opt . "-i " | |
| endif | |
| if &diffopt =~ "iwhite" | |
| let opt = opt . "-b " | |
| endif |
| This introduces a CLI command `yt` which calls `youtube-viewer` | |
| to display a YouTube channel. The YouTube channel IDs are stored | |
| in `~/.config/youtube/` in flat plain text files containing just | |
| the ID. The file name is used as the argument to `yt`. | |
| One way to find out the channel IDs is to paste a URL of a | |
| YouTube video into the `youtube-viewer` prompt. It will | |
| then list the channel ID in the videos metadata. |
| #!/usr/bin/python | |
| from datetime import date, timedelta | |
| from locale import setlocale, LC_ALL | |
| setlocale(LC_ALL, '') | |
| start = date.today() - timedelta(7) | |
| d = start |
| from subprocess import run, CalledProcessError | |
| from time import sleep | |
| CMD = ["wpa_cli"] | |
| def scan_results(_scan=True): | |
| res = [] | |
| proc = run(CMD + ["scan_results"], | |
| check=True, capture_output=True) |
$ unbound-control-setup
$ systemctl enable stubby unbound
$ systemctl start stubby unboundUnbound dumps statistics to syslog every six hours: