Print daylight hours remaining, cache sunrize time from wttr.in
Download, chmod +x suntime.fish
and put it in your PATH
fish
is required to run this script, but doesn't have to be your SHELL
to do it.
You can set a cron job to periodically update sunrize and sunset times:
0 0 */21 * * /path/to/suntime.fish update
If no LOC
is set wttr.in will use geo-ip for location.
You can set this in the script file or like this:
LOC=Stavanger,Norway suntime.fish update
Can chain with other scripts to change themes at sundown:
suntime.fish e && light_theme || dark_theme
License MIT, free to do whatever. Yours to fuck up.
![Screen Shot 2021-11-28 at 09 45 55](https://user-images.githubusercontent.com/132863/143734577-da904ec1-0122-4db7-8800-50b24f6389bf.png)
asciinema.org/a/452003