So like many of you I use del.icio.us to manage my bookmarks. My biggest problem is tag creep. Depending on my state of mind/mood I end up with a lot of useless/duplicated tags. This is particularly the case when I didn't have the Firefox plugin that autocompletes existing tags as you type, or when I click the suggested community tags for a given entry when I have an existing tag that would have fit but maybe was worded differently.
So for a long while I've been wanting to put together a simple app that would bulk rename/merge tags so I could do some cleanup without the hassle of individually editing each post in a tag from the website. However, inertia and being otherwise occupied thwarted those efforts.
Today I took, literally, 5 minutes to leverage Nate Zobrist's very well put together Netlicious API after seeing it in Scott's Weekly Source Code 4.
Basically it's a C# wrapper to the del.icio.us API, and I have to say it's really nice. Following Scott's example I read the source code and it's elegant in its simplicity to be sure. This is a great example of someone taking the time to make an abstraction that, while not that difficult to do, has the potential to provide many developers with a strong platform with which to build better apps. So, thanks for taking the time to do this Nate!
Anyway, my application is about as simple as they come. The actual code part consists of 3 lines of netlicious api calls and its done. This is a testament to the api...the code in my app is totally throw-away. You type the name of the tag you want gone in the "source tag" field, and the name of the new or merge target tag in the "target tag" field and hit "Rename". It's not elegant at all, and of course you have to spell correctly (not case-sensitive however). Prior to doing that you will need to enter your credentials for del.icio.us.
If you want a more full-featured desktop app to manage your del.icio.us stuff, check out Netlicious, also by Nate (for which he wrote the api). It does way more stuff, but to do this simple operation it was just a little too...thick.
So, download VeryTasty here if you wanna. Not including the code because it's literally 2 button click handlers. The pertinent netlicious calls are here:
Delicious.Connection.Username = Properties.Settings.Default.UserLogin;
Delicious.Connection.Password = Properties.Settings.Default.UserPassword;
Delicious.Tag.Rename(txtSourceTag.Text, txtNewTag.Text);
So there you have it. Enjoy.
Technorati tags:
Code,
My Projects