CDs

xrayspx's picture

iTunes Mass Importer

Music: 

Bauhaus - King Volcano

For my own notes, so I don't forget I did this... Big thanks to Doug from Doug's Applescripts for iTunes for convincing me that making iTunes update in this way is possible.

As with all things, I have to make my music library overly complicated. In historical times, I ripped at 128k, then 192k, but even a lot of the 192k mp3s sound like crap, so I've decided that going forward, I'm doing 320k CBR MP3s as well as FLAC.

I'm using Max to do the rip and encode on the Mac. It encodes both sets of files in parallel and saves them in a directory under ~/Music/max-rips/Artist/Title.

Here is a script to sort that and update iTunes. It'll drop the MP3s in my MP3 library directory, then drop the FLACs in a repository for them, finally making iTunes add the new files at the end. If all you want is to make iTunes rescan your library for new files from a script of bash shell, you want the osascript line toward the bottom, just substitute the path to your collection in place of mine.

I'd like to pass $directory and $albumdir to the osascript and have it live inside the inner for loop, but I've not figured out how to use my variables inside the 's that osascript -e requires to run its part. It only takes a few seconds to re-index the whole thing.

This is the utterly fugly 15-minute first draft with crappy variables and whatnot, but it does work.

(Yeah yeah, "find blah blah | while yadda yadda", 15 minutes, works, admittedly fugly, 2000 CDs and nothing has | in the artist or title)
Update #2: Nevermind all that, the script below is a lot clearer and does all that stuff I wanted.

maxmover.sh:


#! /bin/bash

find ./max-rips -depth 1 -type d | awk -F "max-rips/" '{print $2}' | while read artist
  do

    mkdir "/Volumes/Filestore/CDs/$artist"
    mkdir "flac-output/$artist"

    find "./max-rips/$artist" -depth 1 -type d | awk -F "max-rips/$artist/" '{print $2}' | while read album
      do

        mkdir "/Volumes/Filestore/CDs/$artist/$album"
        mv "max-rips/$artist/$album"/*.mp3 "/Volumes/Filestore/CDs/$artist/$album/"
        mv "max-rips/$artist/$album" "flac-output/$artist"

        `/usr/bin/osascript         tell app "iTunes"
        add POSIX file "/Volumes/Filestore/CDs/$artist/$album/"
        end tell
        EOT`

      done

    rm -f "max-rips/$artist"/.DS_Store
    rmdir "max-rips/$artist"

  done

Update:
It looks like there are several ways to skin my osascript cat. These aren't even the most fluid examples I've found.

xrayspx's picture

Mike Watt and The Missing Men @ Brighton Music Hall, 10-17-2012

Music: 

The Pixies - U-Mass

We just walked in from seeing Mike Watt & The Missingmen at the Brighton Music Hall. The latest in our unintentional Punk Rock Legends series, so this is brief.

This blistering set was all of the album Hyphenated-man, which we do not yet own, but will tomorrow. It was pretty much beat poety, jazzy, hardcore rolled up in 2 minute songs.

Watt was looking a little worse for wear from his 2010 knee injury. I'm not surprised, because when we saw him with Iggy Pop (and The Neighborhoods!), just a few weeks after he hurt it, he was in a full immobilizer, and had to get on stage with crutches. Once on stage with a bass in his hands, he proceeded to run around and jump all over the place as if it hadn't happened. He looks like he's feeling it more now, which I know from experience really sucks.

One of the best bits was this cover of Machine Gun by Jimi Hendrix during the encore. This version has better vocal audio than we heard, if I find video of tonight's show, I'll replace this Iowa footage:

Here are the photos, they're not great, because the Brighton Music Hall isn't the brightest lit place in the world, but got some good ones:

xrayspx's picture

Long Tall OCD

Music: 

Wanda Jackson - Long Tall Sally

I have four artists' versions of Long Tall Sally, and am listening to them all in order.

Does anyone else do this when you have three or four versions of a song? I'm driven to, especially when they're really different, like covers of or by Tom Jones, or Shirley Bassey.

xrayspx's picture

Updated Music Collection Browser

Music: 

Nick Cave And The Bad Seeds - The Weeping Song

I've made some much needed updates to my Music Collection Browser, and thought I'd mention it. It now does a case-insensitive sort of artist names, while ignoring leading special characters ( "'",":","(", etc), as well as throwing away leading "The"s for sorting. This was a big deal to me since it annoyed me every time I had to scroll through 50 The Whoevers to get the band I want.

I also fixed the compilations piece, so linked that back in. I just settled for big ugly links for soundtracks/compilations and individual artists at the top of whichever page is loaded. It sucks but there's really not much of a better way to go.

Now I just have to re-tag a few albums and artists to make things consistent, since some artists have both a "The" and "non-The" variant in the list, but at least now they're right next to each other.

Also, I want to vent about Gracenote. Fucking Gracenote. That is all. ... For many artists who have lots of featured guests, it appends all the "feat. whoever"s to the Artist tag. That is wrong. It should be appended, preferably in parentheses, to the song title itself. It's the only way to maintain a reasonable collection.

Of course, iTunes is stupid enough to create different artist folders based on this idiocy, so now I have 15 Bootsy Collins directories on the FS.

The goal list for this project, after 24 hours, now stands at:

  • iTunes XML files
  • Case Insensitivity for sorting
  • Throw away non-alpha/num leading characters to build the list ('Til Tuesday, :wumpscut:, (Cevin) Key, though it would break !!! if we owned any, or else it would just show up first, where 'Til Tuesday is now, which is fine)
  • Throw away leading "The"s for sorting, but only one, so as not to break The The, or Thes One
  • Better handling of compilations
  • Searching
  • Port to PHP?
  • Here's where I justify not crossing the rest of the items off my list:

    (1) I've barely bothered to look at iTunes XML files because every time I open one and try to make sense of it, I end up weeping to myself. I think what it's going to end up being is me taking my iTunes DB and munging into either sqlite3 (probably) or MySQL (unlikely), in a stripped down version of the same form that Amarok built its sqlite3 databases. I can't help but think that all the searches I run against the DB would be slow as hell if I was searching an unindexed XML file every time I do anything. So now I just need to write a perl script to parse the iTunes XML database file and puke out SQLite3 in a schema my site already handles.

    (2) I don't personally care much about searching. The point of this tool is so that when I'm in a record store or otherwise away from my computers I have quick access to an accurate copy of my CD collection, so I don't purchase dupe CDs or whatever. Or if someone asks me if I've heard of some band I can pull it up. Also, helpful links to YouTube, Wikipedia and Amazon searches for each artist. That's pretty useful really. Searching is irrelevant. The only place it would really be handy is if I send the page to someone else and they want to quickly find an artist or song, to which I say "Suck it up and scroll".

    (3) I was thinking of porting it to PHP just because I've written like, 6 lines of PHP and figured I should know it. This thing could stay Perl until Unix time rolls over and I wouldn't care at all.

    xrayspx's picture

    Parental musical advice

    Music: 

    I'm pretty much unqualified to give anyone advice on any topic, but this is the best parental advice I can give:

    Don't let people insult your kids and drive you insane with crappy childrens music.

    A friend posted that she felt bad because she may have waited too long to buy tickets to The Wiggles. As a non-child-owner, I of course had to interject with my option:

    It's OK, you can get these instead, with the benefit of it being Real Music: http://www.danzanes.com/tour

    Fixed Tags:
    xrayspx's picture

    Imelda May @ Brighton Music Hall, 7-30-2011

    Music: 

    Misfits - Hollywood Babylon

    [music | Misfits - Hollywood Babylon]

    [Also-music | Elvis Presley - Blue Suede Shoes]

    xrayspx's picture

    Joe Buck Yourself - 4/14/2010

    Tonight we got to see Joe Buck Yourself at the Brick House in Dover, NH. This show was the biggest coincidence ever. We first saw Joe Buck playing bass with Hank III at the Roxy, and it killed us, and cost me a toenail. I have been waiting to see him solo ever since.

    xrayspx's picture

    What it might look like if I used Twitter

    Almost exactly half my music collection contains "the". Of 15,137 tracks, 7578 have "the" in the Artist, album or track name. So I'm 19 off.

    The reason this came to my attention is that I was searching my collection for The The. iTunes doesn't seem to like that search much and only hits on one "the". Quotes mean nothing to this application. Thanks again Apple.

    xrayspx's picture

    New CDs

    [music | Dr. Octagon - Waiting List (DJ Shadow/Automator Mix)]

    I don't usually post about new CDs, I just get way too many of them. But I've been waiting patiently for two independent CDs and they both came in recently, and I really liked both of them.

    Fixed Tags:
    xrayspx's picture

    Zoe Keating

    [music | Aphex Twin - Windowlicker]

    Fixed Tags:

    Pages

    Subscribe to RSS - CDs