[mythtv-commits] mythtv commit: r23474 by mdean

mythtv at cvs.mythtv.org mythtv at cvs.mythtv.org
Thu Feb 4 22:46:16 UTC 2010


      Author: mdean
        Date: 2010-02-04 22:46:16 +0000 (Thu, 04 Feb 2010)
New Revision: 23474
   Changeset: http://svn.mythtv.org/trac/changeset/23474

Modified:

   trunk/mythtv/contrib/user_jobs/mythrename.pl

Log:

Remove the file-renaming support from mythrename.pl.  Trying to automatically rename recording files based on listings-provided data is causing problems and isn't really necessary.  Instead of renaming files, users should create symlink (with this script--to be renamed mythlink.pl after this change) or FUSE-based (with contrib/exports/mythfs.py) views of recordings.  If there is any strong reason to support "human-readable" file names, such support should probably be added to mythbackend.

After this change, mythrename.pl (soon to be mythlink.pl) with no arguments will create pretty-formatted symlinks under the "show_names" directory of the first storage group directory.  Typically the program will be called with the --link or --dest argument (as before) to specify a destination for the symlinks.  (However, this change means that the default behavior of the script is non-destructive.)

The file-renaming support was changed to only support renaming files back to their default file names and is only used when the --rename argument is specified.  Any --format argument is ignored when the --rename argument is specified.

Though this change looks very invasive in the diff, it mostly just moved the "else" handling renaming to its own subroutine and unshifted code that was previously in an if conditional.  Though the separate subroutine means there is redundant code for setting up and looping over the recordings, the structure will allow easy removal of the "rename to default" code after a release version or so.

Refs #4932.  Refs #7535.





More information about the mythtv-commits mailing list