desertplant / moon-phase-background

Change desktop background to a high resolution picture of the current moon phase from NASA
MIT License
18 stars 4 forks source link
astronomy cinnamon cinnamon-desktop cinnamon-theme desktop desktop-background linux linux-mint linuxmint mint moon moon-phase moonphase nasa open-source space theme wallpaper wallpaper-changer

moon-phase-background

Change background picture to high resolution picture of the current moon phase from NASA

This bash script downloads a high resolution image of the current moon phase from NASAs Dial-A-Moon website https://svs.gsfc.nasa.gov/5187/, adds it onto a background image of stars, labels the image with the phase in percent and the age of the current moon cycle and sets it as a background image on Linux Mint Cinnamon.

best.tif is an example picture. (Resolution 5641x3650 by default, 8192x5641 is possible too.)

For automatic desktop background updates it is recommended to add the script to Startup applications or set a Cron Job.

The downloaded images are deleted again immediately, as not to pollute storage.

Requirements:

In Linux Mint Cinnamon most likely pre-installed:

Installation:

  1. Download the repository and extract the files in some new folder, anywhere you want.
  2. Navigate to your new folder in terminal
  3. Make the script executable by entering chmod u+x moonback.sh

You can then run the script using ./moonback.sh. Note that you need to be in the folder to run the script this way. To run it from anywhere add the path to ~/.bashrc file. Instructions for that are here: https://askubuntu.com/questions/153251/launch-shell-scripts-from-anywhere

It will download a 5MB image file and change your desktop background and then delete the downloaded image again (as not to pollute storage space). The file back.tif is your new background image now.

You can add this script moonback.sh to startup applications to automatically load the new moon phase background on startup.

To automatically update in certain time intervals you can set a cron job. Note that there is a new image available once per hour, so running this more often will not result in change.

Configuration: