-
-
Save aobasar/c0320afef794d4e27e763c6fb84bfe34 to your computer and use it in GitHub Desktop.
Use random photos from Unsplash as a desktop background on Ubuntu
This file contains 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 | |
uuser="unsplash_user_name" | |
path="/home/aobasar/Pictures" | |
mkdir -p $path | |
size=$(xdpyinfo | grep dimensions | awk '{print $2}') | |
#if you dont care user | |
#curl "https://source.unsplash.com/user/$uuser/$size" --location --output $path/unsplash-random.jpeg | |
curl "https://source.unsplash.com/$size" --location --output $path/unsplash-random.jpeg | |
gsettings set org.gnome.desktop.background picture-uri file://$path/unsplash-random.jpeg |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment