1
0
Fork 0
mirror of https://github.com/kastdeur/dotfiles.git synced 2025-06-01 20:09:13 +02:00

Added SXC thingies to dotfiles, allowing for *.local files for bash and profile. Still Needs these files for tmux,vim,git,...

This commit is contained in:
Eric-Teunis de Boone 2016-10-02 23:39:11 +02:00
parent d47333930f
commit 7a82ebe7f1
14 changed files with 41 additions and 2660 deletions

14
bash/scriptlets/wttr Normal file
View file

@ -0,0 +1,14 @@
WTTR=~/.wttr
if [ -f $WTTR ]; then
cat $WTTR
alias wttr='cat $WTTR'
else
read -p "{$Yel}Do you want your weather cronned? " -n 1 -r
echo
if [[ $REPLY =~ ^[Yy]$ ]]
then
cronjob="curl -s wttr.in/Voorthuizen | sec -n 3,7p > $WTTR 2>&1 "
croncmd="27 */2 * * * $cronjob"
( crontab -l | grep -v -F "$croncmd" ; echo "$cronjob" ) | crontab -
fi
fi