Package: himawaripy
himawaripyPut near-realtime picture of Earth as your desktop backgroundhimawaripy is a Python 3 script that fetches near-realtime (10 minutes delayed)
picture of Earth as its taken byHimawari 8 (ひまわり8号)and sets it
as your desktop background.Set a cronjob (or systemd service) that runs in every 10 minutes to automatically get the
near-realtime picture of Earth.Supported Desktop EnvironmentsTestedUnity 7Mate 1.8.1PantheonLXDEOS XGNOME 3Cinnamon 2.8.8KDENot Supportedany other desktop environments that are not mentioned above.Configurationusage: himawaripy [-h] [--version] [--auto-offset | -o OFFSET]
                  [-l {4,8,16,20}] [-d DEADLINE] [--save-battery]
                  [--output-dir OUTPUT_DIR] [--dont-change]

set (near-realtime) picture of Earth as your desktop background

optional arguments:
  -h, --help            show this help message and exit
  --version             show program's version number and exit
  --auto-offset         determine offset automatically
  -o OFFSET, --offset OFFSET
                        UTC time offset in hours, must be less than or equal
                        to +10
  -l {4,8,16,20}, --level {4,8,16,20}
                        increases the quality (and the size) of each tile.
                        possible values are 4, 8, 16, 20
  -d DEADLINE, --deadline DEADLINE
                        deadline in minutes to download all the tiles, set 0
                        to cancel
  --save-battery        stop refreshing on battery
  --output-dir OUTPUT_DIR
                        directory to save the temporary background image
  --dont-change         don't change the wallpaper (just download it)Most of the time himawaripy can accurately detect your timezone if you pass the flag--auto-offset, although you may
also set it manually by-o(or--offset) flag. If your timezone is beyond GMT by more than 10 hours, use the closest
one (either+10or-12).Increasing the level will increase the quality of the image as well as the time taken to download all the tiles and the
memory consumption. For instance choosing 20 will make himawaripy use ~700 MiB of memory at its peak and the image will
be around ~200 MB.You should set a deadline compatible with your cronjob (or timer) settings to assure that script will terminate in X
minutes before it is started again.You might use--save-batteryto disable refreshing while running on battery power.You might also ask himawaripy to not to change your wallpaper by--dont-changeif you would it to download the image and stop.NitrogenIf you use nitrogen for setting your wallpaper, you have to enter this in your~/.config/nitrogen/bg-saved.cfg.[:0.0]
file=/home/USERNAME/.himawari/himawari-latest.png
mode=4
bgcolor=#000000InstallationYou need a valid python3 installation including the python3-setuptools package# Install
pip install --user himawaripy

# Test whether it's working
himawaripy --auto-offset

# Get the installation path of himawaripy by running the command
which -- himawaripy

# Set himawaripy to be called periodically

    ## Either set up a cronjob
        crontab -e

        ### Add the line:
        */10 * * * * <INSTALLATION_PATH> # command line arguments here

    ## OR, alternatively use the provided systemd timer

        ### Configure
        nano systemd/himawaripy.service
        # Replace "<INSTALLATION_PATH>" with the output of the aforementioned command and command line arguments

        ### Copy systemd configuration
        cp systemd/himawaripy.{service,timer} ~/.config/systemd/user/

        ### Enable and start the timer
        systemctl --user enable --now himawaripy.timerFor KDE UsersKDE 5.7+To change the wallpaper in KDE 5.7+, desktop widgets must be unlocked. If you dom't want to leave them unlocked,
the pre-KDE 5.7 method can still be used.To unlock desktop widgets (from the KDE userbase):Open the Desktop Toolbox or the Panel Toolbox or right click on the Desktop - if you see an item labeled Unlock
Widgets then select that, and then proceed to add widgets to your Desktop or your Panel.Before KDE 5.7So the issue here is that KDE does not support changing the desktop wallpaper
from the commandline, but it does support polling a directory for file changes
through the "Slideshow" desktop background option, whereby you can point KDE
to a folder and have it load a new picture at a certain interval.The idea here is to:Set the cron for some interval (say 9 minutes)Open Desktop Settings -> Wallpaper -> Wallpaper Type -> SlideshowAdd the~/.himawaridir to the slideshow listSet the interval check to 10 minutes (one minute after the cron, also
depending on your download speed)Many thanks toxenithorbfor the solution!For Mac OSX UsersOSX has deprecated crontab, and replaced it withlaunchd. To set up a launch agent, copy the provided sampleplistfile inosx/org.boramalper.himawaripy.plistto~/Library/LaunchAgents, and edit the following entries if requiredmkdir -p ~/Library/LaunchAgents/
cp osx/org.boramalper.himawaripy.plist ~/Library/LaunchAgents/ProgrammingArgumentsneeds to be the path to himawaripy installation. Thisshouldbe/usr/local/bin/himawaripyby default, but himawaripy may be installed elsewhere.StartIntervalcontrols the interval between successive runs, set to 10 minutes (600 seconds) by default,
edit as desired.Finally, to launch it, enter this into the console:launchctl load ~/Library/LaunchAgents/org.boramalper.himawaripy.plistUninstallation# Either remove the cronjob
crontab -e    
    # Remove the line
    */10 * * * * himawaripy...

# OR if you used the systemd timer
systemctl --user disable --now himawaripy.timer
rm $HOME/.config/systemd/user/himawaripy.{timer,service}

# Uninstall the package
pip3 uninstall himawaripy<INSTALLATION_PATH>can be found using the commandwhich -- himawaripy.If you would like to share why, you can contact me on github orsend an e-mail.AttributionsThanks toMichaelPotefor theinitial
implementationusing
Powershell Script.Thanks toCharlie Loydfor image processing logic
(hi8-fetch.py).Obviously, thanks to the Japan Meteorological Agency for opening these pictures
to public.