unix stuff

dir2ogg

Important notice

Friday, June 22, 2007

It is no surprise that I have been neglecting dir2ogg a bit over the last year, focusing my efforts on sneetchalizer instead. A gentleman by the name of Julian Andres Klode will be taking over maintaining dir2ogg as of version 0.9.3. I have no doubt that Julian will give dir2ogg the care and love it deserves. He is already working on improvements and is intending to push out a 0.10 release in the next few days. It should also be noted that as of this new version dir2ogg will be moving from the Artistic Licence to the GPL. Also, the script will now use Mutagen to consolidate the scripts meta-tagging.

So: as of today, if you have questions, comments, or bugs to report with the script please contact Julian care of dir2ogg's new website. For historical and sentimental reasons I am going to keep all the 0.9.3 and previous versions of the script available from here, but please, don't use them. Go get the new one.

Godspeed dir2ogg! You were my first project and first companion down the exciting path of free/open source software development. I would like to thank everybody who took the time to send in bug reports, or just a note saying how dir2ogg has helped them over the last four years. It means a lot.

Note for those looking to convert a file _to_ mp3, m4a, or flac

Looking at my webalizer stats I can see that a large number of people are coming to this page using a search query like 'convert m4a to mp3'. dir2ogg does not convert to mp3s, but I am loathe to allow anyone to leave my site unsatisfied so I wrote a new script in Ruby called sneetchalizer. It is basically like dir2ogg except you can convert between any two supported formats. So: If you want to just convert some files to Ogg Vorbis format, go ahead and use dir2ogg. But if you want the Swiss-Army Knife of audio conversion tools, you will want to have a look at sneetchalizer.

Steve Nixon has sent in a shell script which converts a directory of m4a files to mp3. Thanks Steve...
If you are using windows you may want to have a look at BonkEnc. Tip courtesy of Wim Vander Schelden.

download dir2ogg

OSI

Older versions:

Changes

0.9.3 :: July 19, 2006

WMA meta-tags are now preserved if you install my own wmainfo-py library. I have also fixed the '-q' argument so that it may accept any value that is valid for oggenc (ie: '-1' to '10', and decimals: '3.7'). Also, have changed the default -q arg from '4' to '3' to match oggenc's default.

0.9.3_pre1 :: May 21, 2006

Version 0.9.3_pre1 has wma support thanks to a patch from Cameron Stone (camerons AT cse.unsw.edu.au).

0.9.2 :: December 15, 2005

This is 0.9.2_pre1 with a few minor fixes.

0.9.2_pre1 :: September 29, 2005

This is a testing release. It includes support for recursive directory conversion, and also support for embedded id3 tags in m4a files. Please beta test if you can. Barring a showstopper bug, this will be rolled out as dir2ogg 0.9.2.

0.9.1 :: April 1, 2005

This release allows multiple directories to be specified on the command line. Also, there is now support for the 'track number' id3 tag. It will show up as either '5' which shows track 5, or '5,17' which shows track 5 of 17 on the original album.

0.9 :: January 27, 2005

The changes between 0.9 and 0.9pre1 are trivial, so everything below applies to 0.9. To reiterate, your filename _may_ be changed, and error checking for mpg123, oggenc, and faad is included. Have fun!

0.9pre1 :: December 9, 2004

In dir2ogg 0.9pre1 the special characters '"', '*', '!', and ';' will be removed from filenames. The special character '&' will be converted to 'and'. These characters are known to break the script when fed to bash. If you don't like the idea of this script changing your filenames that's fair enough, but I submit these characters have no business being in proper unix filenames anyway. If I get the time I will try to change this so they are escaped rather than removed.

Also in this version, the exit status of mpg123, faad, and oggenc is checked, and should be handled apropriately. This means if you are using the 'x' or 'a' flags, your original file won't be deleted if mpg123 throws an error. Something you would expect of course, but with me it takes time for such 'features' ;)

And finally after two years I added some sanity checks on the filename/directory arguments passed to the script. So now if you mistype a filename you will get a stern warning about your file not being found from dir2ogg instead of a 50 line traceback from python.

0.8 :: September 27, 2004

dir2ogg 0.8 is pretty much a re-write from scratch. The original dir2ogg was not much more than an exercise for me. I was "scratching an itch" as ESR might say. I found myself converting mp3s to oggs quite frequently, and thought that others may be doing this as well, which is why I released dir2ogg in the first place. As my skill in Python increased, I added more features to dir2ogg...and the more I added to my original code the cruftier it got.

dir2ogg is now object-oriented instead of procedural. In addition to hundreds of unseen advantages, this will allow me to add new features in the future easily and cleanly. Along with a base of cleaner and more efficient code, dir2ogg 0.8 includes these benefits:

0.8pre1 :: September 23, 2004

I am putting the finishing touches on a complete re-write of dir2ogg. Version 0.8 is going to be vastly superior to 0.7 for many reasons including full support for GNU-style long and short command line options, extensive exception handling, improved program logic, the ability to specify multiple files on the command line, and many, many more.

0.7 :: August 23, 2004

Version 0.7 has support for converting m4a and wav files to ogg format. To convert m4a files you will need faad installed. This version also fixes some bugs, including adding uppercase file extensions to the list of files to be converted ie: MP3, M4A, and WAV. Even if you don't intend to convert m4a files, you should still use this version.

0.6 :: May 24, 2004

This version introduces new command line flags. Deleting the .wav and .mp3 files is now user-controlled, there is an option to preserve the shell-protected filename, and there is also a verbose flag. Plus the '-dir' flag is now obsolete. Please us 'd' instead. NOTE: the new command line option flags do not need to be preceded by a dash. There cannot be any spaces between options on the command line. See Installation and Usage below...

0.5 :: May 14, 2004

dir2ogg 0.5 is in the Ibiblio Linux Archive.

dir2ogg now allows spaces in your filenames. The script uses sed to convert spaces to underscores, the conversion is made, then the underscores are reverted back to spaces. This is not fool-proof however...some special characters will cause the script to break. dir2ogg tries to deal with this gracefully, but I cannot anticipate every filename possible (there are some doozies when downloading mp3s from windows users ;)). Generally, if you use sensible filenames this will not be a problem for you. Keep in mind that you will still have to escape the filenames for bash ie: dir2ogg "song with spaces.mp3". Using "dir2ogg -dir ." will work fine however. Please read the updated manpage for more details.

0.4 :: October 8, 2003

I have bumped the version number up to 0.4 to reflect its 'stable' status. For almost everyone this is the version you will want to use. Also of note: dir2ogg is now a part of the Ibiblio Linux archive. It's home will always be this page, but my site is not always up...so you will always be able to get it from Ibiblio.

stats

It is Monday May 12, 2008 1:12 am
This page served 55186 times
This page last modified: April 14, 2008 11:28 am
Your IP address is: 38.103.63.18
You are browsing using: CCBot/1.0 (+http://www.commoncrawl.org/bot.html)
You are browsing from: United States.
badcomputer.org's uptime: 01:12:55 up 18 days, 01:55, 1 user, load average: 0.00, 0.00, 0.00

local

home | unix stuff | dir2ogg | sneetchalizer | wmainfo | q&d guide to permissions | q&d guide to tar and gzip | code | MS rant | browser shootout | linux & iAudio X5 | photos | music | programming poetry | sieve of Eratosthenes | plea | rain | suffer | archive | about | recipes | compaqr3000 | sitemap

search

Google

credits

hacker emblem

This page, and all pages on this site were created and are maintained by Darren Kirby using valid XHTML 1.0 and CSS, and are ©copyright 2002 - 2008. The Penguin image was created by Tukka, and is used by permission. Inspiration for the look of this site was provided by Eric A. Meyer's CSS gallery. This website runs on Gentoo Linux. It is served by Apache. PHP and MySQL hold together the backend.

advertisement