You are not logged in.
Pages: 1
I'm usually running foobar with a "countdown-to-kill-playback" component when I go to bed (love mah soft tunes!
), but I'm in the middle of moving, so I'm stuck with my laptop for now. I still want to do the whole timed playback killing though, so I thought I'd just do this:
#!/bin/sh
sleep 90m
killall exaile &I'm sure it's not the cleanest way to do it, but it gets the job done. The problem is I'd also like to have it echo the remaining time. Anyone have a smooth way of doing this?
Edit:
If all else fails, I'll (sort of) happily settle for having it echo a static countdown, but I'm guessing that'll be just as tricky, since if I'm not mistaken "sleep" will halt all activity in the script until the set time runs out, no?
Edit2:
I just thought of something; if I place a 90m countdown first in the script, will it actually wait the allotted time before executing the following line(s)? If so, wouldn't that make using "sleep" unnecessary?
Last edited by Savonlinna (2009-11-09 21:15:36)
"History is the fiction we invent to persuade ourselves that events are knowable and that life has order and direction."
Offline
i would have thought the best approach would be something like
for a in $(seq 90 -1 0); do echo $a "minutes left"; sleep 60s; done- - - - - - - - Wiki Pages - - - - - - -
#! install guide *autostart programs, modify the menu & keybindings
configuring Conky *installing scripts
Offline
Thanks benj1, works like a charm!
"History is the fiction we invent to persuade ourselves that events are knowable and that life has order and direction."
Offline
Pages: 1
Copyright © 2012 CrunchBang Linux.
Proudly powered by Debian. Hosted by Linode.
Debian is a registered trademark of Software in the Public Interest, Inc.