To copy all your music files (including the library file that holds all your playlists and other settings) to your new computer:
1.Locate your Music folder (Mac OS X) on your new computer:Mac OS X: /Users/username/Music
2.Drag the iTunes folder in this location out to the desktop.
3.Locate the iPod on the new Mac: On the desktop.
4.Double-click on the iPod icon to open it.
5.Drag the iTunes folder from the iPod to the Music folder (Mac OS X) on your new computer. This can take a while if you have a lot of songs.
6.Open iTunes.
By that all your music, playlists, and other information like play counts and ratings have all been moved from your old computer to your new one.
More details:
http://support.apple.com/kb/HT1329