[mythtv-users] mythlink.pl

Michael mythtv at blandford.net
Fri Aug 11 15:31:37 UTC 2017


On 08/11/2017 04:22 AM, John Pilkington wrote:
> On 11/08/17 12:05, John Pilkington wrote:
>> On 11/08/17 11:35, Mark Perkins wrote:
>>> Has anyone tried mythlink.pl on 0.28 or 29?
>>>
>>> I note on the wiki that it lists compatibility only as far as 0.27.
>>>
>>> https://www.mythtv.org/wiki/Mythlink.pl
>>
>> I use it regularly, from the command line, in master.  But with a patch:
>>
>> $ diff mythlink.pl mythlink_KN2.pl
>> 4a5,8
>>  > ## With patch by Karl Newman to skip deleted recordings
>>  > ## 
>> http://www.mythtv.org/pipermail/mythtv-users/attachments/20131125/ab4f1992/attachment.obj 
>>
>>  > ## or
>>  > ## http://www.gossamer-threads.com/lists/mythtv/users/558623#558623
>> 352a357,358
>>  >     # Skip deleted recordings
>>  >         next unless ($show->{'recgroup'} ne 'Deleted');
>>
>>
>> John P
>
> Second thoughts again.  I run this:
>
> #!/bin/bash
> # Create a readable list of recordings in /home/john/pretty
> #
> echo "Creating a pretty list of recordings in /home/john/pretty"
> #
> perl 
> /usr/share/doc/mythtv-docs-master/contrib/user_jobs/mythlink_KN2.pl 
> --link \
>  /home/john/pretty --format  '%T-%cn-%Y%m%d-%H%i-%S'
> date
> exit


I also do something like this:


# Removing symlinks breaks plex syncing
# Generate the links in a tmp dir
perl /usr/share/doc/mythtv-docs/contrib/user_jobs/mythlink.pl --path 
/plexdir/TV.tmp --format "%T/%T - S%ssE%ep - %S"

# Sync the changes only to the directory plex reads
rsync -av --delete --ignore-existing /plexdir/TV.tmp/ /plexdir/TV/


I started doing this because I have plex set to notice directory changes 
and automatically update.   Unfortunately, when mythlink ran, the first 
thing it does is remove all links.    Plex would start deleting the meta 
data, to then only recreate it.   Now I run mythlink in a temp diretory 
and have rsync only copy over new or remove deleted links.

Michael



More information about the mythtv-users mailing list