diff --git a/.bash_profile b/.bash_profile index 6c94aba..9152291 100644 --- a/.bash_profile +++ b/.bash_profile @@ -15,3 +15,11 @@ HISTFILESIZE=15000 test -e "${HOME}/.iterm2_shell_integration.bash" && source "${HOME}/.iterm2_shell_integration.bash" +wttr() +{ + # change Paris to your default location + local request="wttr.in/${1-St+Paul+MN}" + [ "$(tput cols)" -lt 125 ] && request+='?n' + curl -H "Accept-Language: ${LANG%_*}" --compressed "$request" +} +