Improve diagnostics when invalid --subtitle specified #6
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi
Thanks so much for this program. It has made my slog through transferring a DVD set i acquired to my media box a breeze.
I ran into an issue though, when i specified
--subtitle=eng
, as suggested (probably not literally, though i had no clue) in the--help
message. Turns out, my DVD only features (inter alia) "English" (unabbreviated), but autohb only told me:So i modified
get_subtitle_track
with some code i copy-pasted fromget_subtitles
to result in the branch i'm requesting being pulled into yours, which, to my illegal--subtitle
specification, ponies up(I have no idea what that last one, "English," with the comma, is. I'm itchin' to try it, though)
Of course, that's at the top of the call stacktrace, so it may not be all that helpful, and my ruby has never been for public consumption, so it may not be exactly a paragon of style, so you may just wanna take the gist of it and do something more suitable for your purposes, if you see any merit at all in this.
Anyways, again, thanks for this very time-saving program.
And, for the record, i was running the version at commit 890781e of Fri Dec 2 22:05:18 2022 +0000 on ubuntu 22.04 (jammy), which (for anybody else with a box running that distro who hasn't done so yet) i got to build courtesy of an
apt-get install ruby-bundler
, anapt-get install ruby-dev
, and anapt-get install g++
(didn't even have a C++ compiler installed on that box) along with replacing the line in the Gemfile that sayswith
which seems to be the version available just after you made that last commit, because the older GNU C++ versions available with "jammy" don't support some of the newer C++ syntax in the latest taglib-ruby version 2.0.0. (I further followed the suggestion in the comment by Iuri Guilherme at Jun 16, 2022 at 15:25 on this stackoverflow answer to
bundle install
the gems locally in my AutoHandbrake directory and then ran it a labundle exec autohb.rb
)