Difference between revisions of "MythTv: Don't scan live tv"

From LinuxMCE
Jump to: navigation, search
(Locating and editing the SaveMythRecording.sh file)
Line 22: Line 22:
 
  #!/bin/bash
 
  #!/bin/bash
 
   
 
   
  dir=/home/public/data/videos/tv_shows
+
  dir=/home/public/data/videos/tv_shows_0
 
   
 
   
 
  mv $3/$4 $dir/$4
 
  mv $3/$4 $dir/$4

Revision as of 04:51, 20 March 2009

Making MythTV LiveTv recordings invisible to LinuxMCE

For those who watch a lot of live TV, you'll notice that LinuxMCE adds all of those LiveTV recordings to the LinuxMCE DB. Not only does this fill up the database, but it makes browsing media quite ugly. There is an easy way to solve this.

Locating and editing the SaveMythRecording.sh file

The file is stored in

/usr/pluto/bin

The first thing to do is make the directory that will hold the recordings:

mkdir /home/public/data/videos/tv_shows


Then make a backup of the SaveMythRecording.sh script:

cp /usr/pluto/bin/SaveMythRecording.sh /usr/pluto/bin/SaveMythRecording.sh.bak


Now edit SaveMythRecording.sh with your favorite program:

#!/bin/bash

dir=/home/public/data/videos/tv_shows_0

mv $3/$4 $dir/$4
touch $3/$4 | chown mythtv:public $3/$4

echo "$(date) $0-$1-$2-$dir-$4" >> /var/log/pluto/donerecording.log
/usr/pluto/bin/MessageSend dcerouter 0 -1001 2 69 29 "$1" 57 "$2" 35 "$dir/$4"

Prevent UpdateMedia from scanning LiveTV recordings

Create a file, /home/public/data/videos/tv_shows_1.folderlock, to prevent scanning:

touch /home/public/data/videos/tv_shows_1.folderlock

Conclusion

Now when browsing Media, LiveTv recording will not show up in the list. Your recordings will never be expired or deleted by MythTv, and MythTv will continue functioning without errors. All LiveTv recordings and scheduled recordings can still be expired and deleted through the MythWeb interface without impacting LinuxMCE.