Skip to content
Create a gist now

Instantly share code, notes, and snippets.

anonymous /

Embed URL


Subversion checkout URL

You can clone with
Download ZIP
#!/usr/bin/env python
# encoding: utf-8
First download your bookmarks and restrict to specific tags if desired:
$ curl --user 'username':'password' -o delicious.xml ''
Extract and count most common domains:
$ python | sort | uniq -c | sort -nr > ranked_delicious_domains.txt
Created by Peter Skomoroch on 2010-08-15.
Copyright (c) 2010 Data Wrangling LLC. All rights reserved.
import sys
import os
from BeautifulSoup import BeautifulStoneSoup
xml = open('delicious.xml', 'rU').read()
soup = BeautifulStoneSoup(xml)
posts = soup.findAll('post')
for i, post in enumerate(posts):
print post['href'].split('/')[2]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.