View Single Post
Old 04-04-2014, 06:41 PM   #4
Eradicatore
i void warranties
Eradicatore can extract oil from cheeseEradicatore can extract oil from cheeseEradicatore can extract oil from cheeseEradicatore can extract oil from cheeseEradicatore can extract oil from cheeseEradicatore can extract oil from cheeseEradicatore can extract oil from cheeseEradicatore can extract oil from cheese
 
Eradicatore's Avatar
 
Posts: 22
Karma: 1038
Join Date: Apr 2014
Location: Wisconsin
Device: Kindle PW2
Thanks knc! That will help for the future for sure.

So I gave up and learned enough python (I've done PERL for 15 years now) to do it.



!/usr/bin/python
import time;
import glob;
import random;
import subprocess;

last = "";
while 1 == 1:
file = random.choice(glob.glob('*.png'));
while file == last:
file = random.choice(glob.glob('*.png'));

last = file;
#print file;
subprocess.call(['eips','-f','-g',file]);
time.sleep(60*60); # switch backgrounds every hour



(btw, what's the way to show code on this forum?)

Last edited by Eradicatore; 04-04-2014 at 06:43 PM. Reason: code formatting bad
Eradicatore is offline   Reply With Quote