Skip to content

Commit

Permalink
Support mediainfo's ever-changing output format 😡
Browse files Browse the repository at this point in the history
  • Loading branch information
mbklein committed Dec 12, 2017
1 parent aaa6464 commit 788d7f2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/mediainfo.rb
Original file line number Diff line number Diff line change
Expand Up @@ -514,7 +514,8 @@ def inspect

private
def mediainfo!
@last_command = "#{path} #{@escaped_full_filename} --Output=XML"
output_format = mediainfo_version > '17.0.0' ? 'OLDXML' : 'XML'
@last_command = "#{path} #{@escaped_full_filename} --Output=#{output_format}"
run_command!
end

Expand Down

0 comments on commit 788d7f2

Please sign in to comment.