Sunday, December 4, 2016

Using Chrome's --disable-extensions-except

As of version 55, Chrome supports the --disable-extensions-except flag, which as you might expect, disables all extensions except the one specified. The trick is that it has to be specified as a path to a folder containing an unpacked extension. For an extension you're building, that's easy, but for ones you got from the store, you have to hunt down the folder where they're kept. Chrome unpacks installed extensions here:

%LOCALAPPDATA%\Google\Chrome\User Data\Default\Extensions

Inside are a bunch of folders each named with an extension's ID. Inside those are folders for versions of the extensions, and those are the folders that have manifest.json. Pass that folder to Chrome like so:

chrome --disable-extensions-except="C:\path\to\versionfolder"

Based on my Super User answer.

No comments:

Post a Comment