Added command to purge addons from database (bug 999119)

I need to add some logging up in here. I was testing with django db logging enabled to see what SQL was being executed but if we were to run this on a server we wouldn't see those.