Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Staying Organized' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Staying Organized
Authored by: beedee on Feb 11, '03 11:15:39AM

I have a good method for keeping my iTunes Library organized when adding new stuff.

First off, I have the "Keep iTunes Music Folder organized" and "Copy files to iTunes Music folder" options enabled. I often download music from various places (emusic subscription, epitonic.com, limewire, etc.). Many times I am downloading new artists/albums that I want to check out, and many times I don't really like everything I've downloaded.

So I always drag my new music into a playlist named "_New". Once I have listened to everything and decided what stays and goes, I delete all the tracks from the playlist that I like (they're still in my iTunes Library), select all the remaining tracks in the playlist, hit Cmd+I, and add the comment "Delete Me", then I go into my main library, type "Delete me" into the search box, and finally I select all the tracks and hit Cmd+delete.

A quicker method (but only usefull if you use it right away), is to just right click on the column titles in the main library window and turn on the "Date Added" column. Then you can sort your library by the day that songs were added to your library and delete what you wish.



[ Reply to This | # ]
Staying Organized
Authored by: tortislc on Feb 11, '03 06:51:33PM

What other techniques are out there to remove duplicate songs automatically? Without manually going through your playlist?



[ Reply to This | # ]
Staying Organized
Authored by: DeltaTee on Feb 12, '03 11:00:10AM

There are many AppleScripts that help to remove duplicate items from the playlists.

If you have a problem with the same physical file being added to the library twice, I would suggest my Remove Duplicates (by Filename) script. (More information is available at http://applescript.plaidcow.net/)

If you find that iTunes "keep music organized" is a little too constraining, I have an Organize Files script that will organize your directory based on any ID3 tag information that you want to use. Rename Files will similarly allow you to rename files based on any ID tag information.

For deleting files from the hard drive (while removing them from the iTunes library) in one fell swoop (directly from iTunes) I have a Delete Files script.

All of these scripts have more information available on my website at http://applescript.plaidcow.net/

Let me know if they can be helpful to you.



[ Reply to This | # ]
Staying Organized
Authored by: hypert on Sep 15, '04 01:06:27AM

You don't need to select all the tracks you want to delete, add a comment, search for the comment in the library, and then press Cmd-Delete. Just select them in your playlist and press Cmd-Opt-Delete. This will remove them from your playlist AND from your Library!



[ Reply to This | # ]
Staying Organized
Authored by: hypert on Sep 15, '04 01:08:57AM
I just submitted this a little while ago as a new "hint", but now that I found this thread, I'll try to post it here. For some reason, I end up with a ton of "duplicate" tracks in my iTunes library and playlists. By this I mean that more than one track in iTunes maps to a single file on my hard drive. (I may get into this problem because I sync my files between my Mac and my PC, and an ID3 tag change made on my PC may cause iTunes on the Mac to think it's a whole new track when I re-drop the files back into iTunes.) Anyway, Doug Adams has some great Applescripts available to find and/or delete "dupes", but they don't always work for me. So, I wrote a Perl script to parse the "Song List" which can be exported from iTunes (in the File menu). There are 25 different "fields" associated with every track in the list, and the Perl script allows you to easily pick which fields you want (by editing the Perl script where documented). Here's the script:

#!/usr/bin/perl -w

use strict;
my $song;
my $lastSong = "";
my @songs;
my $DEBUG = 0;

if (scalar(@ARGV) == 0) {
    print "USAGE: $0 <filename>\n";
    print "The <filename> must be generated from iTunes' \"Export Song List\" function.\n";
    exit 1;
}

{
    # The exported file uses the Mac file delimeter.
    local $/ = "\r";
    my $file = shift;
    open(F, "$file") || die "Cannot open file '$file'.\n";
    @songs = <F>;
    close(F);
}

# Take off header row.
my $header = shift @songs;
if ($DEBUG) {
    # If you set $DEBUG, you'll see what each of the header fields are.
    # You can use this set which of the fields to use when determing dupes
    # (in the "map" statement a few lines down).
    my @header = split("\t", $header);
    for (my $i = 0; $i < $#header; $i++) {
	print "Field $i:\t$header[$i]\n";
    }
    print "\n";
}

# Consider four of the fields (Artist, Name, Album, Size) for the duplication calculation.
# If you set $DEBUG, some code above will print out what each of the header fields are,
# and then you can pick any fields to be included in there duplicate calculation here.
@songs = map { my @fields = split("\t"); "$fields[1]\t$fields[0]\t$fields[3]\t$fields[6]" } @songs;

@songs = sort(@songs);

foreach $song (@songs) {
    print "Looking at $song.\n" if ($DEBUG);
    if ($song eq $lastSong) {
	print "Duplicate: $song.\n";
    }
    else {
	$lastSong = $song;
    }
}


[ Reply to This | # ]