oobe-feisty
October 5th, 2008, 08:50 AM
Imagine being able to update multiple videos that you just added to your mythvideo folder by typing one single command below are screenshots to demonstrate how cool this looks
all tv show info about each episode and screen shots added as pics for mythvideo plus all imdb movie searchs to
that is what this howto covers and somthing i searched for a long time for before the authors of these 2 very nice scripts made them.
download these scripts
metacleanup-0.4.tar.gz at http://www.fecitfacta.com/metacleanup-01-30-09.tar.gz
and http://www.thepisanis.com/files/imdbupdater.tar.gz
make a temp folder
mkdir ~/tmp/meta
cd ~/tmp/meta
unpack them in the ~/tmp/meta folder
tar xvzf metacleanup-0.4.tar.gz
tar xvzf imdbupdater.tar.gz
later on we will put them somewhere more permanent
metacleanup requires modifying so open metacleanup.sh with you favourate text editor
joe metacleanup.sh
you need to edit these parimters
# Myth Database Name
DBNAME=mythconverg
# SQL Server Hostname (usually localhost)
SQLSERVER=localhost
# Myth DB User
DBUSER=mythtv
# Myth DB Password
DBPASSWORD=mythtv
# Where do your movies live? (Root MythVideo Directory)
MOVIEHOME=/movies
# Where do your posters live? (Mythvideo Poster Dir)
POSTERHOME=/home/mythtv/.mythtv/MythVideo
DBNAME should be fine as is
SQLSERVER should be ok unless your on a remote frontend
DBUSER should be fine unless you changed it in which case you would already know about as you probably have needed to modify many things in the past
DBPASSWORD get you password from /etc/mythtv/mysql.txt
MOVIEHOME=/path/to/tveps i keep my tveps in one folder and my movies in another i instruct metacleanup.sh to use tveps only here although for some reason it will update everything ../ anyway which im ok with
POSTERHOME=/home/oobe/.mythtv/MythVideo path to movie posters
quick shortcut
here is a small script that i use instead of having to remember all the syntax for imdbupdater ( you will need to edit cd /path/to/script/folder and replace yourpassword with your mythtv password from mysql.txt)
#!/bin/bash
cd /path/to/script/folder
cd imdbupdater
## this line searchs for any files that are not in the mythvideo database then adds them (this way you do not have to go to utility's / setup in mythfrontend and rescan your videos)
##you will need to edit the path
./imdb-bulk-update.pl -Host localhost -User mythtv -Password yourpassword -Fileup -Folder /data/Documents/media/vids
#runs metacleanup.sh it does not require any paremeter's
cd ..
./metacleanup.sh
#adds any movies it finds in you movies folder you will need to edit the path you will be prompted if more that one title exists if it fails to find movie you will not be prompted
cd imdbupdater
./imdb-bulk-update.pl -N -Host localhost -User mythtv -Password yourpassword -Fileup -Folder /data/Documents/media/vids/moviez
# this line does the same as above however if you missed out on any that it could not find it will prompt you for a imdb number
./imdb-bulk-update.pl -N -Host localhost -User mythtv -Password yourpassword -Manual -Fileup -Folder /data/Documents/media/vids/moviez
save it to the same folder
UPDATE: this now works without prompting very well thanks to and update to the metacleanup.sh
as you can see if you read the comments this will not work without prompting i.e if you want to add it as a cronjob it will not work
you can simply add this line to a text file and make it executable then set it to run as a cronjob
./imdb-bulk-update.pl -Host localhost -User mythtv -Password yourpassword -Fileup -Folder /data/Documents/media/vids
i dont feel the need to do this but i have seen people want to add this feature to mythtv
once you test it all and your happy move the folder to somewhere permanent might i suggest /usr/share/mythtv/mythvideo/scripts
this way you will have /usr/share/mythtv/mythvideo/scripts/meta
you can now copy your saved script to /usr/local/bin/myscript i called mine auto for some reason
now all you have to do is type myscripts and it will run all the above commands you can do the same if you choose to make a cronjob as mentioned above.
all tv show info about each episode and screen shots added as pics for mythvideo plus all imdb movie searchs to
that is what this howto covers and somthing i searched for a long time for before the authors of these 2 very nice scripts made them.
download these scripts
metacleanup-0.4.tar.gz at http://www.fecitfacta.com/metacleanup-01-30-09.tar.gz
and http://www.thepisanis.com/files/imdbupdater.tar.gz
make a temp folder
mkdir ~/tmp/meta
cd ~/tmp/meta
unpack them in the ~/tmp/meta folder
tar xvzf metacleanup-0.4.tar.gz
tar xvzf imdbupdater.tar.gz
later on we will put them somewhere more permanent
metacleanup requires modifying so open metacleanup.sh with you favourate text editor
joe metacleanup.sh
you need to edit these parimters
# Myth Database Name
DBNAME=mythconverg
# SQL Server Hostname (usually localhost)
SQLSERVER=localhost
# Myth DB User
DBUSER=mythtv
# Myth DB Password
DBPASSWORD=mythtv
# Where do your movies live? (Root MythVideo Directory)
MOVIEHOME=/movies
# Where do your posters live? (Mythvideo Poster Dir)
POSTERHOME=/home/mythtv/.mythtv/MythVideo
DBNAME should be fine as is
SQLSERVER should be ok unless your on a remote frontend
DBUSER should be fine unless you changed it in which case you would already know about as you probably have needed to modify many things in the past
DBPASSWORD get you password from /etc/mythtv/mysql.txt
MOVIEHOME=/path/to/tveps i keep my tveps in one folder and my movies in another i instruct metacleanup.sh to use tveps only here although for some reason it will update everything ../ anyway which im ok with
POSTERHOME=/home/oobe/.mythtv/MythVideo path to movie posters
quick shortcut
here is a small script that i use instead of having to remember all the syntax for imdbupdater ( you will need to edit cd /path/to/script/folder and replace yourpassword with your mythtv password from mysql.txt)
#!/bin/bash
cd /path/to/script/folder
cd imdbupdater
## this line searchs for any files that are not in the mythvideo database then adds them (this way you do not have to go to utility's / setup in mythfrontend and rescan your videos)
##you will need to edit the path
./imdb-bulk-update.pl -Host localhost -User mythtv -Password yourpassword -Fileup -Folder /data/Documents/media/vids
#runs metacleanup.sh it does not require any paremeter's
cd ..
./metacleanup.sh
#adds any movies it finds in you movies folder you will need to edit the path you will be prompted if more that one title exists if it fails to find movie you will not be prompted
cd imdbupdater
./imdb-bulk-update.pl -N -Host localhost -User mythtv -Password yourpassword -Fileup -Folder /data/Documents/media/vids/moviez
# this line does the same as above however if you missed out on any that it could not find it will prompt you for a imdb number
./imdb-bulk-update.pl -N -Host localhost -User mythtv -Password yourpassword -Manual -Fileup -Folder /data/Documents/media/vids/moviez
save it to the same folder
UPDATE: this now works without prompting very well thanks to and update to the metacleanup.sh
as you can see if you read the comments this will not work without prompting i.e if you want to add it as a cronjob it will not work
you can simply add this line to a text file and make it executable then set it to run as a cronjob
./imdb-bulk-update.pl -Host localhost -User mythtv -Password yourpassword -Fileup -Folder /data/Documents/media/vids
i dont feel the need to do this but i have seen people want to add this feature to mythtv
once you test it all and your happy move the folder to somewhere permanent might i suggest /usr/share/mythtv/mythvideo/scripts
this way you will have /usr/share/mythtv/mythvideo/scripts/meta
you can now copy your saved script to /usr/local/bin/myscript i called mine auto for some reason
now all you have to do is type myscripts and it will run all the above commands you can do the same if you choose to make a cronjob as mentioned above.