by oPromessa, 2024, V0.0.1
Published on https://github.com/oPromessa/imdb2vsmeta/
If you own a Synology NAS and make use of Video Station.
And need a quick easy way to populate your Movie Library with Metadata.
imdb2vsmeta is the answer!
I run it off a Mac with access to the NAS video folder.
I place the Video folders to be scanned outside the Movies Library (normally video/Movies) in a temp/staging folder video/Staging.Area (Still on the NAS, to make it fast but not scanned as a Library!)
It looks for Media (.mkv, .mpg, .avi, and .mp4) files named "Movie Title (Year)" format.
Use the option --search-prefix to operate in batch modes and process only files starting with say A: --search-prefix A
It then looks for the Movie metadata in IMDB
It then generates the corresponding .vsmeta file to update Video Station
Side Note: poster and background images are the same.
You must move back your fodlers/files from video/Stagin.Area into /video.Movies
Once the process is complete you can move back the Movie folders into the video/Movies Library
...and see the magic happens ;)
python3.11 -m venv venv
source venv/bin/activate
pip install imdbmovies
pip install requests
pip install click
pip install vsmetaEncoder
Example
python imdb2vsmeta.py --search /Volumes/video/Staging.Movies/ --verbose --search-prefix Sugar --series --no-copy
Options
Usage: imdb2vsmeta.py [OPTIONS]
Searches on a folder for Movie Titles and generates .vsmeta file and copies
them over to your Video Station Library
IMPORTANT: Use a Staging area on your NAS to generate .vsmeta and only
then, add them to you Video Library.
It generates the temp files *.jpg and *.vsmeta on the current folder. You
can then remove them.
Options: --movies Specify if it is a movie. Must choose movies or series. NOTE: This argument is mutually exclusive with arguments: [series]. --series Specify if it is a series. Must choose movies or series. NOTE: This argument is mutually exclusive with arguments: [movies]. --search DIRECTORY Folder to recursively search for media files to be processed into .vsmeta. NOTE: This argument is mutually exclusive with arguments: [check]. --check PATH Check .vsmeta files. Show info. Exclusive with --search option. NOTE: This argument is mutually exclusive with arguments: [search]. --search-prefix TEXT Media Filenames prefix for media files to be processed into .vsmeta. Eg: --search-prefix A -f, --force Force copy if the destination file already exists. NOTE: This argument is mutually exclusive with arguments: [no_copy]. -n, --no-copy Do not copy over the .vsmeta files. -v, --verbose Shows info found on IMDB. --help Show this message and exit.
* --check option generates the temp files *.jpg and *.vsmeta on the local folder. You can then remove them.
#### Screenshots on How to use
* Moving Files to Staging Area...and back once you run the tool.
![Moving files to Staging Area](doc/Staging.Area.jpg)
* Resulting Metadata
![Metadata of Movie](doc/Movie.jpg)