Created
November 9, 2021 15:40
-
-
Save nitheeshkm/4206529581a6173b339cd623cee1aa4a to your computer and use it in GitHub Desktop.
get wallpaper from unsplash and set it as background
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| if [[ $(nmcli -t -f GENERAL.METERED dev show wlp111s0) = 'GENERAL.METERED:no (guessed)' ]]; then | |
| wget -O /var/tmp/wallpaper.jpg https://source.unsplash.com/3840x1080/?wallpaper,mars && | |
| gsettings set org.gnome.desktop.background picture-uri file:///var/tmp/wallpaper.jpg | |
| fi | |
| eog /var/tmp/wallpaper.jpg |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
wget -O /var/tmp/wallpaper.jpg https://source.unsplash.com/3840x1080/?ultrawide