[mythtv-users] was add season and episode number to parameters for mythlink.pl

Jason Flatt jflatt at cox.net
Thu Sep 27 15:36:06 UTC 2012

(sorry if this gets messed up, my phone doesn't allow me to bottom-post)
Absolutely, there's a few improvements to these scripts that could be made.  I'm not proficient in perl, so I just tacked on a couple more variables to support season/episode.  It is consistent with the rest of the script.  It looks like perl can support sprintf and strftime, which can be used to cut this script nearly in half.  Also, the mythlink.pl should be able to query Program.pm for the list of formatters that can be used, so that they don't need to be maintained in two places.  I can take a look at these issues when I find time.
One other note, in my testing of about 10 very recent recordings, only about 5 of them had season and episode numbers, with the output format results being zeroes.  Of course, your results may be different.On 9/26/12 11:34 PM Raymond Wagner wrote:
On 9/26/2012 23:24, Jason Flatt wrote:
> +        $rseason = "0$rseason"   if ($rseason < 10);
> +        $repisode = "0$repisode" if ($repisode < 10);

Surely Perl has a better mechanism than that to provide zero padding.
mythtv-users mailing list
mythtv-users at mythtv.org

More information about the mythtv-users mailing list