[mythtv-users] ANN: Vacation scheduling
John Johnson
johnatl at mac.com
Tue Jul 11 22:52:57 UTC 2006
Someone mentioned vacation scheduling a while back.
I've written a script to implement this, if anyone is interested in
trying it out.
You can find it here:
http://groups.yahoo.com/group/johnjohnsonsoftware
in the Files section, it is called myth_vacation.
Put it in /usr/local/bin or where ever you want.
Edit the file and change the settings at the top (just the usual host,
user, password, etc.).
As root, run the script with the --install option.
The script should create a couple of symlinks, an entry in the mythtv
user's crontab, and a People recording rule called On Vacation.
The rules that you want to turn on/off based on if you are on vacation
or not should be assigned to a Vacation recording group.
When you are ready to go on vacation, go to Manage Recordings | Schedule
Recordings | Search Words | People and set the On Vacation rule active.
The next time cron runs the myth_vacation script, it will notice you've
changed On Vacation, and set all recordings in the Vacation group to
inactive.
When you return from vacation, set On Vacation inactive. The script will
see the change, and set all recordings in the Vacation group to active.
I know all the active/inactive is confusing, but I didn't name the field :-)
Here's another way to schedule your vacation time.
The script has two options to make it easy to start and stop vacation
time. Use the --begin option to set vacation begin time, and the --end
option to set the vacation end time. The script uses the 'at' command to
schedule itself to run at the appropriate times.
Here's an example:
myth_vacation --begin "10:00 pm tomorrow" --end "8:00 am Aug 3"
To see more of the ways you can specify times, see 'man at'.
Note that the netflix_watcher script is available from this group as well.
Regards,
JJ
More information about the mythtv-users
mailing list