dbr / tvnamer

Automatic TV episode file renamer, uses data from thetvdb.com via tvdb_api
https://pypi.python.org/pypi/tvnamer/
The Unlicense
912 stars 115 forks source link

Move subtitles along with video files #66

Closed lahwaacz closed 11 years ago

lahwaacz commented 11 years ago

Hi, I've been using this program only for an hour, so maybe I missed something, so I'll ask first: I've noticed that the program renames subtitles as well, but the problem is that I have subtitles in two different languages for most of the episodes, so my collection basically looks like this: episode1.avi episode1.eng.srt episode1.cze.srt and so on. Tvnamer renames the first subtitle to episode1.srt and then obviously fails on the second. I tried to specify 'valid_extensions': ['eng.srt','cze.srt','avi'] in the config, but that doesn't work because os.path.splitext() splits only the last part ('srt'). Is there some way to configure this? If not, I'd like to file a feature request.

lahwaacz commented 11 years ago

I've changed the utils.py to handle subtitles with language code matching video file name. Here's the sample of code: https://gist.github.com/4642562