Blogger Hacks, Categories, Tips & Tricks

Wednesday, January 10, 2007
Re: Scripted Re-Mark Re-Released
Readers may be interested to know that the Scripted Re-Mark bookmarking utility has been updated. Previously launched on Freshblog, I've taken onboard the freedbacking therein and the re-hashed Scripted Re-Mark now sports the following features:
  • It works again. Yes, changes in the delicious interface crippled it. Sadly, I was travelling and unable to fix it. Thanks to those for pointing out the problem, and even better - the solution!

  • Supports functions-as-parameters. Strictly for the hard-core, this means you can now get it to operate on your titles, tags etc with JavaScript functions. Eg use toUpperCase() on your text. Or whatever you like. Dangerous in the wrong hands, please read the instructions. I'm curious to know what people will make of this.

  • Zip through. Faster operation since it will now only use that pesky delay on the bookmarks that it changes. If no rule changes the bookmark, it will jump straight to the next one without waiting. Now you can ruin your bookmarks even faster!

As always, I love getting comments so please send 'em in: horror stories, bugs, fixes, extensions, navel-gazing, use-cases - and especially your regexps and (shudder) functions.

*** Update ***

I've bolted more bells and whistles on to this power tool. It now supports tag stemming. Suppose you have similar tags like blog, blogging and blogs. Scripted Re-Mark can detect that these are similar (ie share a common stem, blog) and rename accordingly. Great for rationalising your tagspace, especially with plurals, tenses and the like.

There's also new support for a "touched tag" ie a tag that is added to all bookmarks that are updated. This is handy for multi-stage processing and manually reviewing edits.

I'm always looking out for more ideas, so please send them in!

*** UPDATE ***

Bowing to public pressure, Scripted Re-Mark now features a mass delete option. Wanna make some bookmarks drink the grape-flavoured Kool-Aid? Now you can ...

Please, be careful with this as it has the potential to inflict much sadness.

Filed in: , , , ,
Posted at 12:38 AM by Greg.
<    >
Blogger Gil said...
thank you so much for making this great tool. took me a few seconds to follow up on the thread, get myself to your tool page and fix everything. well done dude.

<    >
Anonymous Anonymous said...
Why is it that when I enter my ID and a tag it only returns a fraction of my bookmarks that have the tag? Is there a bookmark limit?

<    >
Blogger Greg said...
Yes, delicious has a limit of 100 items in its JSON feed.

This is why you can only see the first 100 bookmarks or so, just enough to see how the search/replace is working.

<    >
Anonymous Anonymous said...
Thanks for the nice post!

<    >
Blogger Ironick said...
Many thanks for Scripted Re-Mark. It rocks. However, I just ran into a problem with it today.

I was using it to change "not shared" bookmarks to shared. I successfully used it on about 3 pages of 100 bookmarks each, with a 4 second delay.

Then on the next page something went wrong. I started the script in the address edit box and the CPU went to 100% and stayed there for a couple minutes. Normally what happens is the first Ajax edit "mini-page" appears and then 4 seconds later the next edit mini-page appears, etc.

Not this time. After several minutes of 100% CPU, ALL the mini-pages flashed for a second and then the page was back to normal. Unfortunately, none of the "not shared" bookmarks had been changed.

I tried several more times. No luck. I restarted FF. No luck. I even started FF with a clean/empty profile. No luck.

Any idea what is going on? Below is the script I am using. Thanks in advance for your help.

javascript: delay=4; ruleSet=[]; sharing=2; touched="touchedC20071106"; var s=document.createElement("script"); s.type="text/javascript"; s.src=""; document.getElementsByTagName("head")[0].appendChild(s); void(0);

<    >
Blogger Greg said...
Thanks for your descriptive bug report.

I guess first and foremost - have you been throttled back by This usage scenario sounds like you might have tripped their threshold.

Give it a few hours and try again. Hopefully it will Just Work again.

The other possibility: is there an "unusual" bookmark on that 4th page? I'm thinking a really long URL, or perhaps a "weird" character or some sort of funny escape sequence - something like that? Did it work, for instance, on the 5th page?

Lastly, I notice you have no rules in your ruleset (which is perfectly valid and usually works). Can I suggest trying a "null" rule, like swapping "http" with "http" in the URL field (ie won't effect any change, but will apply to each bookmark).

Let us know how you get on!

<    >
Blogger Ironick said...
Greg, great suggestion on trying other pages of bookmarks. It turned out the only page 19 of the 34 recently imported bookmarks caused a problem. And I think I found the offending URL:

I'm not sure it is a legal URL, but it is the type of URL the the Internet Archive actually uses. Could having what appear to be two concatenated URLs in the URL field cause this problem?

Thanks again for all your help.

<    >
Blogger Greg said...
The URL is kosher and I think you've hit on a likely suspect. I've stepped through my code, looking for a poorly-formed regular expression or something but found nothing.

In fact, with the empty ruleSet, that code is not even executed.

It might be more complicated; after all, I'm torturing the page's DOM and javascript code to do my bidding, which is sort of error-prone.

I can't recreate it myself, so I'll have to ask you if you've tried excluding that URL or modifying it in some way? Were there any error messages? What about in IE?

Thanks for reporting this bug - it sounds like you've got most of the work done so I appreciate if you're not interested in chasing it up any further.

eXTReMe Tracker