How to integrate iTunes Library?

1,456 views
Skip to first unread message

Simon Szustkowski

unread,
Feb 10, 2014, 4:53:05 AM2/10/14
to beets...@googlegroups.com
Hi,

since tuneUp Media is stopping their service in some days, i am thinking about using beets now for managing my music collection. But there's one thing i am unclear about:
How do i create a coexistence of beets and iTunes?

Currently my whole music is managed by itunes, in its own folder, and i let iTunes copy new tracks to this folder. This was my workflow for years (since 2005).
So i am stuck finding a solution for now.

I managed to figure out i have to do the following steps:
- Install Beets
- Specify a folder where my music is stored
- Run beets
- ???
- Profit

I think it is not the best idea, to let beets run over the current itunes music directory, so i would create a new directory, put my music in there, and run beets, right?
But how do i import this folder to itunes? I think i should deselect the option that itunes should manage its music on its own, e.g. uncheck "Copy new tracks into the music folder".
But how will iTunes be notified when beets changes something? I fear that iTunes won't find a renamed track then. And how do i add new music to the collection? Does beets have an import folder or something?

Since i have around 40k tracks, i think, just playing around with the settings is not very effective, since it would need long time to reorganize the library and stuff.

Has someone figured out how to create coexistence between itunes and beets?

Adrian Sampson

unread,
Feb 11, 2014, 1:00:43 PM2/11/14
to beets...@googlegroups.com
There’s no prescribed way to manage an interaction between iTunes and beets. This plan sounds like a reasonable one, though:

> I think it is not the best idea, to let beets run over the current itunes music directory, so i would create a new directory, put my music in there, and run beets, right?
> But how do i import this folder to itunes? I think i should deselect the option that itunes should manage its music on its own, e.g. uncheck "Copy new tracks into the music folder".
> But how will iTunes be notified when beets changes something? I fear that iTunes won't find a renamed track then. And how do i add new music to the collection? Does beets have an import folder or something?

You might be interested in the “importfeeds” plugin, which I believe Fabrice originally wrote to ease interaction with iTunes. The idea is that it writes to a known location either a bunch of symlinks or an m3u file containing newly imported music. You can drag either of these into the iTunes window to add your new music.

Adrian

Michael MacLeod

unread,
Feb 11, 2014, 2:32:49 PM2/11/14
to beets...@googlegroups.com
Personally the thing I would most like is the ability to set the sort-artist, sort-album-artist, and sort-album tags on files in beets. When I drag a beets sorted album with a few featured artist tracks into iTunes it fills up my artist view with tons of extra tracks. This is a particular problem with most hip hop releases of the last decade, which almost always have guest lyrics.



--
You received this message because you are subscribed to the Google Groups "beets" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beets-users...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Adrian Sampson

unread,
Feb 11, 2014, 2:36:18 PM2/11/14
to beets...@googlegroups.com

On Feb 11, 2014, at 11:32 AM, Michael MacLeod <mikem...@gmail.com> wrote:

> Personally the thing I would most like is the ability to set the sort-artist, sort-album-artist, and sort-album tags on files in beets.

Does the current functionality suffice for this?

$ beet modify foo artist_sort=bar

We also have an albumartist_sort field, but no album_sort field yet.

Michael MacLeod

unread,
Feb 11, 2014, 3:11:51 PM2/11/14
to beets...@googlegroups.com
That would work, but I'd like a way to have beets always set that value at import time (and a way to easily run it against my existing collection which is not insignificant).


Adrian Sampson

unread,
Feb 11, 2014, 3:14:12 PM2/11/14
to beets...@googlegroups.com
Aha, interesting. I presume you mean setting it automatically (along the lines of how the “the” plugin works), yes?

I’ve been thinking about adding similar functionality as an extension of how the “modify” command works—i.e., letting it use templates and run automatically at import time. Notes here:

Michael MacLeod

unread,
Feb 11, 2014, 3:22:55 PM2/11/14
to beets...@googlegroups.com
Yeah, that's the idea. I guess this should have been a separate thread, but to bring it back to iTunes I want this because a 12 track hip hop album could easily have 8 or 10 different artist tags, and iTunes will sort them relatively cleanly in it's interface but not on my iPod nano which will list each as a separate artist if that's how I'm searching my library. It means I'd have to use the album view in order to listen to the entire album.

Mark Sigler

unread,
Dec 27, 2014, 11:05:11 PM12/27/14
to beets...@googlegroups.com

I have about 35K tracks in iTunes and have been using MusicBrainz Picard to update tags prior to moving files to Automatically Add To iTunes folder. This has been good for additions, but is too manual for the existing library. Glad to have found beets as a OS X tool with CLI to tackle the existing library.

I choose to update the files in situ. My config is:

library: ~/Music/beetslibrary.blb
directory: ~/Music/iTunes/'iTunes Media'/Music

import:
    copy: no
    write: yes
    resume: yes
    log: beetslog.txt

match:
    strong_rec_thresh: 0.1
    preferred:
        countries: [US, GB|UK]
        media: [CD, Digital Media|File]
        original_year: yes

I also have Dupin and other of Doug's AppleScripts for iTunes, and Music Folder Files Not Added script is handy for finding errant files that seem to be missing from iTunes library and are buried in the filesystem.

I have also considered iTunes Match, Google Music, et al but hate to concede.

Fabrice Laporte

unread,
Jan 6, 2015, 5:42:20 PM1/6/15
to beets...@googlegroups.com
FWIW I redacted a note back in the days , which describe how to inject music into itunes
it's basically my current workflow except that I use buckets plugin now that did not exist at the time of writing

Paul Marsh

unread,
May 3, 2016, 9:56:39 PM5/3/16
to beets
I am also trying to use beet alongside itunes. I am still trying to figure out an optimized workflow.
 My itunes collection is around 100K tracks. I always run any incoming music thru musicbrainz picard (with the last.fm.plus plugin) before importing to itunes. There are always some tracks that dont get recognized (mainly IMHO due to the fact that picard does not easily use information from discogs). I have begun also running my music thru beet before importing - primarily to leverage the lastgenre plugin. lastgenre seems to work a lot better than the last.fm.plus picard plugin. I do the following to a folder of music before importing:

beet -l ~/tempdb.blb import -C -A -p -s ./
beet -l ~/tempdb.blb write
beet -l ~/tempdb.blb remove

I am now trying to figure out easy way to do something similar to files that are already in the itunes music file structure (obviously not renaming the files in any way). I have had limited success sofar. I can select a group of tracks in itunes and copy them to the clipboard. The clipboard then contains the paths of all the selected itunes tracks separated by spaces. I then run the following command - pasting the clipboard contents at the end.

beet -l ~/tempdb.blb import -C -A -p -s (paste clipboard here)
beet -l ~/tempdb.blb write
beet -l ~/tempdb.blb remove

It works well enough i guess. I then use an applescript to get itunes to refresh its database with the new tag information:

tell application "iTunes"
    refresh selection
end tell

I have experimented with using $(pbpaste) in a script instead of pasting directly into the terminal app but it seems that the contents of the clipboard change depending on the application you are pasting to. in this case if you past to terminal.app you get file paths. if you paste into a text editor (or use $(pbpaste) ) you get the column text contents displayed by itunes instead of a file path.

My next wish is to find an applescript that will do what these 3 commands do with the files i have selected in itunes. Maybe I should post in this group to see how feasible this is?

I will also second Makr Sigler in giving props to "doug" of dougscripts. There are so many useful tools on his website. The single most useful tool being the wonderful Dupin.app. The killer feature is the rating/skip-count/last-played history consolidation feature and the re-playlist feature that fixes playlists containing tracks that have been removed by the process.




Reply all
Reply to author
Forward
0 new messages