Re: Schedules Direct JSON grabber (tv_grab_sd_json) added to CVS
Robert Eden <[email protected]>
| Newsgroups | gmane.comp.tv.xmltv.devel |
|---|---|
| Message-ID | <[email protected]> |
On 5/16/2016 7:44 PM, Kevin Groeneveld wrote: > On Sun, May 15, 2016 at 1:59 AM, Robert Eden <[email protected] > <mailto:[email protected]>> wrote: > > I removed the "File::HomeDir::my_home" requirement and configured > it to > use XMLTV::Config_file module to generate the tv_grab_sd_json.cache > file. Question for the group.. is this how other working file > locations are assigned? Seemed reasonable to me. (That file is a data > cache, the grabber only downloads items that have changed) > > > I agree that it would be nice to remove the File::HomeDir dependency. > Although I don't think the XMLTV::Config_file::filename function was > originally intended to be used this way. The second parameter is named > "progname" to which is being passed "tv_grab_sd_json.cache". The > resulting filename is then "tv_grab_sd_json.cache.conf". The filename > ending in .conf implies to me it is a configuration file not a cache file. > > Looking quickly at the other grabbers I did not see any that use a > single cache file but there are several that use a cache directory. > Several of the grabbers include there own > get_default_cachedir sub which checks various Windows and unix env > variables to determine a home dir. At least two of the grabbers I > looked at repeat very similar code in these functions. It would be > nice if this was brought out into a common shared location in a way > that can handle cache directories and cache files (and other potential > data files) in a consistent manner. Ah, didn't realize I was creating a .cache.conf file. It was a quick hack, I should have actually looked at the output file. I looked at the get_default_cachedir stuff and it really just hard-codes home. I went ahead and cheated again... I generate the XMLTV::Config_file::filename, but now remove the .conf at the end. Robert ------------------------------------------------------------------------------ Mobile security can be enabling, not merely restricting. Employees who bring their own devices (BYOD) to work are irked by the imposition of MDM restrictions. Mobile Device Manager Plus allows you to control only the apps on BYO-devices by containerizing them, leaving personal data untouched! https://ad.doubleclick.net/ddm/clk/304595813;131938128;j _______________________________________________ xmltv-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/xmltv-devel