exe file that installs extension only works when Chrome not running

1,292 views
Skip to first unread message

mikewertheim

unread,
Mar 29, 2011, 4:17:08 PM3/29/11
to Chromium-extensions
I'm developing a Windows exe file (implemented using NSIS) that
installs an extension into Chrome.

The program copies the extension's file hierarchy into $LOCALAPPDATA
\Google\Chrome\User Data\Default\Extensions and copies the preferences
file into $LOCALAPPDATA\Google\Chrome\User Data\Default\Preferences.

If Chrome is not running, then the exe file works great. After
running the exe file, if you start up Chrome, the Extensions tab shows
that the extension has been successfully installed.

However, if the exe file is run while Chrome is running, nothing
happens.

Can anyone provide some insight into what's going wrong and how to fix
it?

Finnur Thorarinsson

unread,
Mar 30, 2011, 6:41:24 AM3/30/11
to mikewertheim, Chromium-extensions
I'm not sure we support the way you are doing it now. This is the normal process for deploying extensions like this:

This will work the same way (install the extension on Chrome startup) and will also make it really easy for you to uninstall/upgrade the extension as well.  If we do change Chrome to detect during run-time whether to install external extensions, we'd be much more likely to change that for the official way of deploying (external extensions) than to start scanning the extension directories periodically.


--
You received this message because you are subscribed to the Google Groups "Chromium-extensions" group.
To post to this group, send email to chromium-...@chromium.org.
To unsubscribe from this group, send email to chromium-extens...@chromium.org.
For more options, visit this group at http://groups.google.com/a/chromium.org/group/chromium-extensions/?hl=en.


Finnur Thorarinsson

unread,
Mar 30, 2011, 6:45:29 AM3/30/11
to mikewertheim, Chromium-extensions
And, as I read this thread again I realize your approach it is not just unsupported, it will never work (I missed the part about modifying the preferences file). We read the preferences file in at startup and when we shut down we write the in-memory contents of that file back to disk again. If you have modified it in the meantime, we'll just overwrite your changes. 

But look at the link I sent, it should set you on the right track.
Reply all
Reply to author
Forward
0 new messages