This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
# http://gist.github.com/gists/2998853/ | |
# Forked from http://gist.github.com/gists/124242 | |
filename, quality = ARGV[0], ARGV[1] | |
abort "Usage: flac2mp3 FLACFILE [V2|V1|V0|320]\nDefault (and recommended) quality is V0." if filename.nil? | |
qualarg = case quality | |
when "V0","V1","V2" then quality | |
when "320" then "b 320" |