Skip to content

Instantly share code, notes, and snippets.

@jhsu
Created July 26, 2011 21:38
Show Gist options
  • Save jhsu/1108125 to your computer and use it in GitHub Desktop.
Save jhsu/1108125 to your computer and use it in GitHub Desktop.
get recent 50 tracks of a user from last.fm
#!/usr/bin/env bash
curl -s "http://ws.audioscrobbler.com/2.0/user/$1/recenttracks.rss?limit=50" | grep -E '^\s+<title>' | sed 's/^[ \t]*<title>//;s/<\/title>[ \t]*$//'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment