Change the wallpaper with an image of space

Customizing Linux is quite a pleasant task and one of the best ways is to change the wallpaper for one that identifies us, that is why an application called nasa-wallpaper has emerged that allows us to visualize the space from our wallpaper.

What is nasa-wallpaper?

It is a terminal application that allows you to change the wallpaper of a Linux system by obtaining the image from the NASA servers. This is fed by the Open Data distributed by NASA itself.

NASA_ID: iss040e008244

This program has two main download options:

  • Download the APOD (Astronomy Picture of the Day), this is an image published daily by NASA of our universe.
  • Find the image in the NASA Image Library, where thousands of documents are housed.

In addition, the output of the program always writes data on what the image means or represents, to contribute to astronomical dissemination (in English).

The supported desktop environments are GNOME, Cinnamon, MATE, LXDE, and XFCE; for the moment.

Installation

Debian and derivatives

Download the .deb file from https://github.com/davidpob99/nasa-wallpaper/releases , at the time of publishing this blog the program is in version 1.0, so the file name is nasa-wallpaper_1.0_all.deb

Go to the folder where you downloaded the file and run $ sudo dpkg -i nasa-wallpaper_1.0_all.deb

Arch Linux

The program is hosted by the AUR, so just run $ yaourt -S nasa-wallpaper

Compiling from code

Clone the repository: $ git clone https://github.com/davidpob99/nasa-wallpaper
Enter the directory: $ cd nasa-wallpaper
Give execute permissions to the file: $ chmod -x ./nasa-wallpaper
Run the file: $ ./nasa-wallpaper

With this last method the program is only accessible by executing it from the folder in which it is downloaded

Operation

The basic syntax is: $ nasa-wallpaper < opciones secundarias > [-T entorno de escritorio] [opciones principales]

-T:  can get the values gnome, cinnamon, mate, lxde y xfce.

All of the following examples will assume a GNOME desktop environment.

As I said before, you can choose where to download the background from (APOD and NASA Library), so there are two main options:

APOD

Basic syntax: $ nasa-wallpaper -T gnome -a Download the image of the day of the day itself (logically).
Choose the APOD of a specific day, for example March 27, 1999: $ nasa-wallpaper -d 1999-03-27 -T gnome -a

NASA Image Library

Basic syntax: $ nasa-wallpaper -T gnome -n Download a random image from the NASA repository.
Download a random image with the keyword earth: $ nasa-wallpaper -w earth -T gnome -n.
Download a random image with the keyword Mar and search from the year 2016 onwards: $ nasa-wallpaper -w mars -y 2016 -T gnome -n.
Download a random image with the keyword galaxy , looking for the year 2015 onwards and that is taken from California: $ nasa-wallpaper -w mars -y 2015 -l california -T gnome -n.

Advanced

It is possible to define advanced parameters such as changing the API key or searching in various fields such as the photographer who took the photo. To know all the possible options write $ man nasa-wallpaper o $ nasa-wallpaper -h. You can also consult the reference online: https://github.com/davidpob99/nasa-wallpaper/wiki/Reference

Run at startup

Open the file /etc/rc.local with nano: $ sudo nano /etc/rc.local
Edit it by adding the desired command before exit 0, for example to download the APOD add nasa-wallpaper -T gnome -a ||exit 1.
Reboot.

License

Another positive point of this application is its open nature. Its code can be consulted at GitHub and use respecting the Apache 2.0 license

Contributing

If you think you can help the development of the program, you can do so by entering GitHub