pastebin

Paste #78723: Untitled Bash paste by 77.9.100.58

#!/bin/bash

# Script to randomly set Background from files in a directory

# Directory Containing Pictures
DIR="/home/chi/Pictures/"

# Command to Select a random jpg file from directory
# Delete the *.jpg to select any file but it may return a folder
PIC=$(ls $DIR/*.jpg | shuf -n1)

# Command to set Background Image
# gconftool -t string -s /desktop/gnome/background/picture_filename $PIC
killall -9 wbar
feh --bg-scale $PIC
wbar -pos top &

Private
Wrap long lines

3 + 2 =