• Apfeltalk ändert einen Teil seiner Allgemeinen Geschäftsbedingungen (AGB), das Löschen von Useraccounts betreffend.
    Näheres könnt Ihr hier nachlesen: AGB-Änderung
  • Viele hassen ihn, manche schwören auf ihn, wir aber möchten unbedingt sehen, welche Bilder Ihr vor Eurem geistigen Auge bzw. vor der Linse Eures iPhone oder iPad sehen könnt, wenn Ihr dieses Wort hört oder lest. Macht mit und beteiligt Euch an unserem Frühjahrsputz ---> Klick

Gibt's irgendwo Playlists zum runterladen?

Tekl

Fairs Vortrefflicher
Registriert
01.06.05
Beiträge
4.630
Hi,

ich hab recht viele Songs in meinen Bibliothek, aber hauptsächlich nur meinen Musikgeschmack in Playlisten organisiert. Gibt es irgendwo Playlisten für iTunes zum runterladen? Also z. B. Musik der 90er. Ich bin mir sicher, dass ich viel passendes in meiner Bibliothek dazu habe. Vermutlich müssen aber Titel, Album und Interpret exakt übereinstimmen, damit das zu meiner Bibliothek passt, oder?

Gibt's vielleicht noch bessere Möglichkeiten?

Edit: Die automatischen Listen sind nicht das gelbe vom Ei, da sie ja nicht wissen, welches Songs damals so hip waren.
 

Tekl

Fairs Vortrefflicher
Registriert
01.06.05
Beiträge
4.630
Genius sucht mir ja nur ähnliche Songs. Ich möchte gerne alle Songs die 1993 in den Charts waren und sich in meiner Bibliothek befinden.
 

Tekl

Fairs Vortrefflicher
Registriert
01.06.05
Beiträge
4.630
Hi,

ich habe mir nun ein rudimentäres Skript gebastelt, welches eine Trackliste in Textedit in der Form "Interpret - Song" oder "Interpret <TAB> Song" erwartet, so wie es vielfach bei Samplern auf Amazon zu finden ist. Das Skript erstellt eine Playlist mit dem Namen der Datei in Textedit wo alle gefundenen Songs eingetragen werden. Gefundene Songs werden zudem in Textedit gelöscht.

Ist alles noch Quick'n'Dirty, aber schon brauchbar:

Code:
tell application "TextEdit" to set playlistName to "♯ " & name of document 1
set oldDelims to AppleScript's text item delimiters

tell application "iTunes"
	if not (playlist playlistName exists) then
		make new playlist with properties {name:playlistName}
	end if
end tell

tell application "TextEdit"
	if not (paragraph 1 of document 1 contains " - ") then
		set AppleScript's text item delimiters to ASCII character 9
	else
		set AppleScript's text item delimiters to " - "
	end if
	if paragraph 1 of document 1 contains "<artist> - " or paragraph 1 of document 1 contains "<artist>\t" or paragraph 1 of document 1 contains "<interpret> -" or paragraph 1 of document 1 contains "<interpret>\t" then
		set artistFirst to true
	else
		set artistFirst to false
	end if
	
	repeat with counter from 1 to (count of paragraphs of document 1)
		try
			if not (first character of paragraph counter of document 1 is (ASCII character 10) or second character of paragraph counter of document 1 is (ASCII character 10)) then
				set myline to paragraph counter of document 1
				if artistFirst is true then
					set myTitle to my strip_spaces(text item 2 of myline)
					set myArtist to my strip_spaces(text item 1 of myline)
				else
					set myTitle to my strip_spaces(text item 1 of myline)
					set myArtist to my strip_spaces(text item 2 of myline)
				end if
				tell application "iTunes"
					try
						set firsttrack to (first track of library playlist 1 whose name contains myTitle and artist contains myArtist)
						try
							if not ((database ID of firsttrack) is in (database ID of every track in playlist playlistName)) then
								add (get location of firsttrack) to playlist playlistName
								tell application "TextEdit" to set paragraph counter of document 1 to ASCII character 10
							else
								tell application "TextEdit" to set paragraph counter of document 1 to ASCII character 10
							end if
						on error
							add (get location of firsttrack) to playlist playlistName
							tell application "TextEdit" to set paragraph counter of document 1 to ASCII character 10
						end try
					on error
						-- Zweiter Versuch
						set myTitle to my strip_more(myTitle)
						set myArtist to my switch_artistName(my strip_more(myArtist))
						try
							set firsttrack to (first track of library playlist 1 whose name contains myTitle and artist contains myArtist)
							try
								if not ((database ID of firsttrack) is in (database ID of every track in playlist playlistName)) then
									add (get location of firsttrack) to playlist playlistName
									tell application "TextEdit" to set paragraph counter of document 1 to ASCII character 10
								else
									tell application "TextEdit" to set paragraph counter of document 1 to ASCII character 10
								end if
							on error
								add (get location of firsttrack) to playlist playlistName
								tell application "TextEdit" to set paragraph counter of document 1 to ASCII character 10
							end try
						end try
					end try
				end tell
				
			end if
		end try
	end repeat
end tell

set AppleScript's text item delimiters to oldDelims
beep

on strip_spaces(aLine)
	--strip lead spaces
	set ods to AppleScript's text item delimiters
	set AppleScript's text item delimiters to {ASCII character 10}
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to {ASCII character 9}
	set aLine to text item 1 of aLine
	repeat until first character of aLine is not " "
		
		set AppleScript's text item delimiters to {""}
		set aLine to (characters 2 thru -1 of aLine as string)
	end repeat
	
	--strip tail spaces
	repeat until last character of aLine is not " "
		log aLine
		set AppleScript's text item delimiters to {""}
		set aLine to (characters 1 thru -2 of aLine as string)
	end repeat
	set AppleScript's text item delimiters to ods
	
	return aLine
end strip_spaces

on strip_more(aLine)
	set ods to AppleScript's text item delimiters
	set AppleScript's text item delimiters to " & "
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to " vs. "
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to " vs "
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to " versus "
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to " feat. "
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to " feat "
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to " f/"
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to " featuring "
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to " with "
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to " w/"
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to " ("
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to " ["
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to " /"
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to "/"
	set aLine to text item 1 of aLine
	set AppleScript's text item delimiters to ods
	
	return aLine
end strip_more

on switch_artistName(aLine)
	set ods to AppleScript's text item delimiters
	set AppleScript's text item delimiters to ", "
	try
		set aLine to (text item 2 of aLine) & " " & (text item 1 of aLine)
	end try
	set AppleScript's text item delimiters to ods
	
	return aLine
end switch_artistName

Edit: Das Skript kommt nun auch mit Interpreten wie "Davis, Miles" klar
Edit2: Man kann nun über die erste Zeile die Reihenfolge bestimmen, also "<interpret> - <titel>" oder auch "<titel> TAB <interpret>
 
Zuletzt bearbeitet:

MacAlzenau

Golden Noble
Registriert
26.12.05
Beiträge
22.513
Im iTunes Store gibt es massenhaft Wiedergabelisten, sowohl unter Playlist als auch - und vor allem - unter den iTunes Essentials, und etliche davon sind auch ganz gut (musst aber schauen, bei den neueren Playlist gibt es fast nur noch welche, wo Leute einfach ihre Musik von einzelnen Interpreten zusammengefasst haben).
 

MacAlzenau

Golden Noble
Registriert
26.12.05
Beiträge
22.513
Genius sucht mir ja nur ähnliche Songs. Ich möchte gerne alle Songs die 1993 in den Charts waren und sich in meiner Bibliothek befinden.

Macht dein Skript das ansatzweise?
Ein großes Manko von iTunes ist, daß man externe Listen nicht mit der Bibliothek abgleichen kann (zumindest habe ich da noch nie eine Lösung gefunden). Ich kann zwar eigene Listen exportieren, aber eben keine anderen importieren -nicht mal, wenn dann nur die vorhandenen Titel angezeigt würden.
Ich habe mal endlos viel Zeit verplempert, Chartlisten mit der Mediathek abzugleichen, dann aber aufgegeben, weil man das bei jedem Neuzugang manuell wiederholen müsste.
Aber wenn jemand eine Idee für ein Skript oder Progrämmchen hätte...
 

Tekl

Fairs Vortrefflicher
Registriert
01.06.05
Beiträge
4.630
Ich verstehe nicht wie das mit den Essentials funktionieren soll, ich kann die Songs ja nur kaufen.

Ja, ich habe mir z. B. mittels http://www.goodtimedj.com/90'sLists.html ein Liste in Textedit erstellt (muss man etwas umformatieren) und das Skript sucht passende Songs in der Mediathek und setzt sie in die Playlist.
 

Spunkie

Boskoop
Registriert
31.05.07
Beiträge
41
Hast du es mal mit einer intelligenten Wiedergabeliste versucht? Dabei kannst du einstellen, dass du z. B. nur Songs haben möchtest die 1993 rausgekommen sind, wenn das Jahr in deinen Titeln vorhanden ist.
 

Tekl

Fairs Vortrefflicher
Registriert
01.06.05
Beiträge
4.630
Klar, ich habe recht komplexe verschachtelte intelligente Wiedergabelisten, doch leider sind die immer noch voll von unpassenden Songs, denn auch 1993 gab's nicht nur gute Lieder. Das Problem ist ja, dass mein Musikgeschmack nichts mit meiner Mediathek zu tun hat. Da sind halt auch viele CDs drin, die ich mal gekauft habe aber selber gar nicht mehr höre. Auf privaten Parties sieht das aber anders aus, da kommt dann der Wunsch, mal was aus den 90ern zu spielen und dann will ja keiner Lieder hören, die damals schon keiner mochte. Ich möchte auch nicht Songs löschen, sondern meine Alben komplett halten.

Die Bewertungsfunktion nutze ich für mich privat, da gibt's Songs mit 5 Sternen, die auf keine Party passen. Ich bräuchte noch mindesten drei zusätzliche Bewertungsmöglichkeiten: Partytauglichkeit für Ältere Semester, für Alternative/Indie/Rock/Metal-Fans und für Mainstream-Fans. Aber würde noch mehr Arbeit bedeuten. Die Popularität von Songs wird doch überall ermitteln, das sollte man doch irgendwie in iTunes reinbekommen.