#!/usr/bin/env ruby | |
require 'rubygems' | |
@dir = ARGV[0] | |
@i = 0 | |
Dir.glob("#{@dir}/*.mp3").each do |mp3| | |
ogg = mp3.gsub('mp3', 'ogg') | |
system "ffmpeg -i \"#{mp3}\" -acodec libvorbis -ac 2 \"#{ogg}\"" | |
@i += 1 | |
end | |
puts "Converted #{@i} mp3s to ogg format!" |
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
Show comment Hide comment
sergiotapia
commented
Aug 24, 2012
Thanks for sharing, helped me out big time! |
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
Show comment Hide comment
NarekChang
commented
Aug 29, 2016
Please, tell me how i can convert dir of oggs to mp3s |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks for sharing, helped me out big time!