Skip to content

Instantly share code, notes, and snippets.

View fabian-mv's full-sized avatar
🇨🇷

Fabián Montero fabian-mv

🇨🇷
View GitHub Profile
@fabian-mv
fabian-mv / torchecker.sh
Created July 26, 2020 21:32
script that checks if TOR service is running and working properly
#!/bin/bash
until $(systemctl is-active --quiet tor.service)
do
printf "Tor is \u001b[31mINACTIVE\u001b[0m, activating...\n"
sudo systemctl start tor.service
done
printf "Tor is \u001b[32mACTIVE\u001b[0m, checking IP address...\n"
@fabian-mv
fabian-mv / ascii_progress.py
Created December 12, 2017 19:56 — forked from and3rson/ascii_progress.py
ASCII progress bar generator (useful for CLI apps & tiling WM widgets)
"""
Author: Andrew Dunai <andrew@dun.ai>
Original code & symbol collection: Changaco <https://changaco.oy.lc/unicode-progress-bars/>
Example GIF: https://habrastorage.org/files/c28/461/630/c28461630bdf46d18be788352a2ef468.gif
Example screenshot: http://public.dun.ai/public/screenshots/148456797191.jpg (left & right widget)
>>> print progress(1, 100, 42, 10)
⎹████▂▁▁▁▁▁⎸
>>> print progress(1, 10, 3, 20, style=1)