Greasemonkey userscripts in Chrome

greasemonkey userscript chrome chromium

Sat Jan 17 11:49:14 -0500 2009

Google Chrome has a lot of potential as a browser, and the semi-recent addition of userscript support has seen it fulfill even more of its potential. In this post I’ll quickly explain how to add userscripts to Google Chrome.

When Chrome was initially released, I used it for a few days and was very impressed with a number of features. For me, however, a ‘day-to-day’ web browser needs to be able to run userscripts at the bare minimum, and add-ons/extensions if possible. I like being able to customize my browsing experience, as there are a lot of things about the web that I simply can’t tolerate (eg. pervasive advertising).

As Chrome now supports userscripts, it is now my main browser, when working in Windows. Unfortunately this is still a Windows-only feature, so when I’m using other platforms (most of the time, now), I’m still a Firefox guy.

How it is done

In order to get the most recent builds of Chrome, you need to first subscribe to the Developer Release Channels. Install Chrome, then visit this page for more information on changing your release channel. Come back when you’ve got a recent version installed.

Once you’ve got a recent version of Chrome installed, follow these steps to add userscript support:

  1. Edit the Chrome shortcut so that the target is run with the ”–enable-greasemonkey” flag. When this is done, the Target field of the shortcut properties should read something like this: “C:\Users\Joel Tulloch\AppData\Local\Google\Chrome\Application\chrome.exe” –enable-greasemonkey Note the quotes around the path, followed by a space, then the flag.

  2. Finally, copy the userscripts (files with the extension user.js) to the c:/scripts/ directory. This directory is hardcoded at the moment, and scripts must be copied there manually, although I’m sure that will change in the near future.

And that’s it. Restart Chrome and your scripts will be picked up.

blog comments powered by Disqus