LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General > LinuxQuestions.org Member Success Stories
User Name
Password
LinuxQuestions.org Member Success Stories Just spent four hours configuring your favorite program? Just figured out a Linux problem that has been stumping you for months?
Post your Linux Success Stories here.

Notices


Reply
  Search this Thread
Old 02-22-2017, 09:24 AM   #1
dugan
LQ Guru
 
Registered: Nov 2003
Location: Canada
Distribution: distro hopper
Posts: 11,193

Rep: Reputation: 5307Reputation: 5307Reputation: 5307Reputation: 5307Reputation: 5307Reputation: 5307Reputation: 5307Reputation: 5307Reputation: 5307Reputation: 5307Reputation: 5307
Wallpaper Randomizer


I haven't tested this on filenames with spaces yet.

Code:
files=(~/Pictures/wallpaper/*)
feh --bg-tile "${files[RANDOM % ${#files[@]}]}"
BASH code is from here:

http://stackoverflow.com/a/701975
 
Old 03-24-2017, 07:16 PM   #2
Myk267
Member
 
Registered: Apr 2012
Location: California
Posts: 422
Blog Entries: 16

Rep: Reputation: Disabled
Quote:
Originally Posted by dugan View Post
I haven't tested this on filenames with spaces yet.

Code:
files=(~/Pictures/wallpaper/*)
feh --bg-tile "${files[RANDOM % ${#files[@]}]}"
BASH code is from here:

http://stackoverflow.com/a/701975
This is a little late but, whenever I see this, I want to comment: feh already has a randomize option.
 
1 members found this post helpful.
Old 03-24-2017, 09:31 PM   #3
frankbell
LQ Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Ubuntu MATE, Mageia, and whatever VMs I happen to be playing with
Posts: 19,257
Blog Entries: 28

Rep: Reputation: 6119Reputation: 6119Reputation: 6119Reputation: 6119Reputation: 6119Reputation: 6119Reputation: 6119Reputation: 6119Reputation: 6119Reputation: 6119Reputation: 6119
I use this in Fluxbox.

Code:
#!/bin/sh

while true; do
       fbsetbg -f -R [path/to/wallpapers}
	sleep 30m
done
I adapted it from something I found on the FVWM website when I played with it several years ago.

Last edited by frankbell; 03-24-2017 at 09:32 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Password randomizer Nicushor Programming 11 09-08-2015 05:38 PM
LXer: Use Wallpaper Clocks, Live Earth Wallpaper In Ubuntu With Slidewall LXer Syndicated Linux News 0 08-12-2012 05:21 PM
Refreshing Desktop Wallpaper - Address of Wallpaper beanus Linux - Desktop 4 07-16-2007 01:57 PM
Wallpaper: SLide show wallpaper from online pictures eponymous Linux - Software 0 11-29-2004 01:28 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General > LinuxQuestions.org Member Success Stories

All times are GMT -5. The time now is 04:12 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration