From f0d8a2304e75c8c4c30afb18da5803e2ceddb122 Mon Sep 17 00:00:00 2001 From: Adam Hovorka Date: Sat, 12 Oct 2019 22:17:27 -0600 Subject: Sync misc changes 20191012 --- base/zsh/functions.zsh | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) (limited to 'base/zsh/functions.zsh') diff --git a/base/zsh/functions.zsh b/base/zsh/functions.zsh index 57f11d3..f1a54f5 100644 --- a/base/zsh/functions.zsh +++ b/base/zsh/functions.zsh @@ -17,7 +17,9 @@ function trash { # 43 0 * * 3 find ~/.trash -mindepth 1 -mtime +90 -delete wttr() { - curl -q -H "Accept-Language: ${LANG%_*}" wttr.in/"${1:-Pleasant Grove}\?${2:-0q}" + curl -q -s --compressed -H "Accept-Language: ${LANG%_*}" \ + "https://wttr.in/${1:-Pleasant Grove}?${2:-0q}" + # "format=%l%0A%c+%t+%w+%m" } hex() { @@ -33,3 +35,13 @@ trc() { ssh dhd.ahov.co ssh aristotle transmission-remote-cli fi } + +httpless() { + http --pretty=all --print=hb "$@" | less -R +} + +colors() { + for i in `seq 0 21`; do + echo -ne "\e[48;5;${i}m ${i} " + done; echo -e "\e[0m" +} -- cgit v1.2.3-70-g09d2