[mythtv-users] Filenames and UTC

Stephen Worthington stephen_agent at jsw.gen.nz
Tue Apr 30 13:21:12 UTC 2013


On Tue, 30 Apr 2013 12:31:09 +0000, you wrote:

>Quoting Stephen Worthington <stephen_agent at jsw.gen.nz>:
>> Scripts should not be creating file names from the start times, if
>> that is what is going on here.
>
>In my case I have a cron job that runs mythfilldatabase and then  
>searches the program table for titles not seen in the last eleven  
>months. It emails me the program title and description with a URL that  
>points to the program in mythweb. The URL is in the form  
>/program/$chanid/$starttime but $starttime has to be in unix timestamp  
>format and UTC.

So this is a bash script?  If so, then the "date" command can provide
all the different time formats you would ever need.  I had to deal
with UTC/local time conversions to make my free storage space
balancing script work.  Take a look at it for some examples of using
"date" to do conversions:

  http://www.jsw.gen.nz/mythtv/balance_storage.sh


More information about the mythtv-users mailing list