Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(263)

Side by Side Diff: chrome/common/extensions/docs/static/external_extensions.html

Issue 9963120: Introduces an additional extension loader that load extra extensions based on per-extension json fi… (Closed) Base URL: https://src.chromium.org/svn/trunk/src/
Patch Set: Created 8 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « chrome/common/extensions/docs/external_extensions.html ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <div id="pageData-name" class="pageData">Other Deployment Options</div> 1 <div id="pageData-name" class="pageData">Other Deployment Options</div>
2 <div id="pageData-showTOC" class="pageData">true</div> 2 <div id="pageData-showTOC" class="pageData">true</div>
3 3
4 <p> 4 <p>
5 Usually, users install their own extensions. 5 Usually, users install their own extensions.
6 But sometimes you might want an extension 6 But sometimes you might want an extension
7 to be installed automatically. 7 to be installed automatically.
8 Here are two typical cases: 8 Here are two typical cases:
9 </p> 9 </p>
10 10
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 and the ID is <code>aaaaaaaaaabbbbbbbbbbcccccccccc</code>. 75 and the ID is <code>aaaaaaaaaabbbbbbbbbbcccccccccc</code>.
76 </p> 76 </p>
77 77
78 <h2 id="preferences">Using a preferences file</h2> 78 <h2 id="preferences">Using a preferences file</h2>
79 79
80 <p class="note"> 80 <p class="note">
81 <b>Windows note:</b> 81 <b>Windows note:</b>
82 Until <a href="http://crbug.com/41902">bug 41902</a> is fixed, 82 Until <a href="http://crbug.com/41902">bug 41902</a> is fixed,
83 you might want to use the <a href="#registry">Windows registry</a> 83 you might want to use the <a href="#registry">Windows registry</a>
84 instead of the preferences file. 84 instead of the preferences file.
85 </p>
85 86
87 <p class="note">
88 <b>Note:</b>
89 Previous versions of Google Chrome used an
90 <code>external_extensions.json</code> file to specify which extensions to
91 install. This file has been deprecated in favor of individual <code>.json</code>
92 files, one per extension.
86 </p> 93 </p>
87 94
88 <ol> 95 <ol>
89 <li>If you are installing from a file, make the <code>.crx</code> extension 96 <li>If you are installing from a file, make the <code>.crx</code> extension
90 file available to the machine you want to install the extension on. 97 file available to the machine you want to install the extension on.
91 (Copy it to a local directory or to a network share for example, 98 (Copy it to a local directory or to a network share for example,
92 <code>\\server\share\extension.crx</code> 99 <code>\\server\share\extension.crx</code>
93 or <code>/home/share/extension.crx</code>.) 100 or <code>/home/share/extension.crx</code>.)
94 </li> 101 </li>
95 <li>Locate the <code>external_extensions.json</code> file. 102
96 If the file doesn't exist, create it. 103 <li>Create a file with the following name in one of the folders listed below:
104 <code>aaaaaaaaaabbbbbbbbbbcccccccccc.json</code> where the file name (without the extension)
105 corresponds to your extension's ID.
97 The location depends on the operating system. 106 The location depends on the operating system.
98 <dl> 107 <dl>
99 <dt> Windows: </dt> 108 <dt> Windows: </dt>
100 <dd> <code><em>chrome_root</em>\Application\<em>chrome_version</em>\Extensio ns\</code> 109 <dd> <code><em>chrome_root</em>\Application\<em>chrome_version</em>\Extensio ns\</code>
101 <br /> 110 <br />
102 Example: <code>c:\Users\Me\AppData\Local\Google\Chrome\Application\6.0.422.0 \Extensions\</code> 111 Example: <code>c:\Users\Me\AppData\Local\Google\Chrome\Application\6.0.422.0 \Extensions\</code>
103 </dd> 112 </dd>
104 <dt> Mac OS X:</dt> 113 <dt> Mac OS X:</dt>
105 <dd>For a specific user: <code>~USERNAME/Library/Application Support/Google/ Chrome/External Extensions/</code><br> 114 <dd>For a specific user: <code>~USERNAME/Library/Application Support/Google/ Chrome/External Extensions/</code><br>
106 For all users: <code>/Library/Application Support/Google/Chrome/External Extensions/</code> 115 For all users: <code>/Library/Application Support/Google/Chrome/External Extensions/</code>
107 <p>The external extensions file for all users is read only if every director y in the path is owned by the user <code>root</code>, has the group <code>admin< /code> or <code>wheel</code>, and is not world writable. The path must also be free of symbolic links. These restrictions prevent an unprivileged user from ca using extensions to be installed for all users. See <a href="#troubleshooting"> troubleshooting</a> for details.</p> 116 <p>The external extension file for all users is read only if every directory in the path is owned by the user <code>root</code>, has the group <code>admin</ code> or <code>wheel</code>, and is not world writable. The path must also be f ree of symbolic links. These restrictions prevent an unprivileged user from cau sing extensions to be installed for all users. See <a href="#troubleshooting">t roubleshooting</a> for details.</p>
108 <p class="note"> 117 <p class="note">
109 <b>Note:</b> The above path for all users was added in Chrome 16. Prior ver sions used a different path:<br/> 118 <b>Note:</b> The above path for all users was added in Chrome 16. Prior ver sions used a different path:<br/>
110 <code>/Applications/Google Chrome.app/Contents/Extensions/</code> 119 <code>/Applications/Google Chrome.app/Contents/Extensions/</code>
111 This path was deprecated in version 17. Support was removed in version 20. Use one of the paths above instead.</p> 120 This path was deprecated in version 17. Support was removed in version 20. Use one of the paths above instead.</p>
112 </dd> 121 </dd>
113 122
114 <dt> Linux: </dt> 123 <dt> Linux: </dt>
115 <dd> <code>/opt/google/chrome/extensions/</code> <br> 124 <dd> <code>/opt/google/chrome/extensions/</code> <br>
125 </dd>
126 <dd> <code>/usr/share/google-chrome/extensions/</code> <br>
116 <b>Note:</b> Use <code>chmod</code> if necessary 127 <b>Note:</b> Use <code>chmod</code> if necessary
117 to make sure that <code>extensions/external_extensions.json</code> 128 to make sure that the <code>aaaaaaaaaabbbbbbbbbbcccccccccc.json</code> files
118 is world-readable. 129 are world-readable.
119 </dd> 130 </dd>
120 </dl> 131 </dl>
121 </li> 132 </li>
122 <li> Add an entry to <code>external_extensions.json</code>
123 for your extension's ID. If you are installing from a file, specify the
124 extension's location and version with fields named "external_crx" and
125 "external_version".
126 133
134 <li>If you are installing from a file, specify the extension's location and vers ion with fields
135 named "external_crx" and "external_version" in the file created above.
136 <p>
127 Example: 137 Example:
128 <pre>{ 138 <pre>
129 "aaaaaaaaaabbbbbbbbbbcccccccccc": { 139 {
130 "external_crx": "/home/share/extension.crx", 140 "external_crx": "/home/share/extension.crx",
131 "external_version": "1.0" 141 "external_version": "1.0"
132 } 142 }
133 }</pre> 143 </pre>
134 144 </p>
135 <p class="note"> 145 <p class="note">
136 <b>Note:</b> 146 <b>Note:</b>
137 You need to escape 147 You need to escape
138 each <code>\</code> character in the location. 148 each <code>\</code> character in the location.
139 For example, 149 For example,
140 <code>\\server\share\extension.crx</code> would be 150 <code>\\server\share\extension.crx</code> would be
141 <code>"\\\\server\\share\\extension.crx"</code>. 151 <code>"\\\\server\\share\\extension.crx"</code>.
142 </p> 152 </p>
143 <p> 153 <p>
154 <p>
144 If you are installing from an update URL, specify the extension's update URL 155 If you are installing from an update URL, specify the extension's update URL
145 with field name "external_update_url". 156 with field name "external_update_url".
146 </p> 157 </p>
147 Example: 158 Example:
148 <pre>{ 159 <pre>{
149 "aaaaaaaaaabbbbbbbbbbcccccccccc": { 160 "external_update_url": "http://myhost.com/mytestextension/updates.xml"
150 "external_update_url": "http://myhost.com/mytestextension/updates.xml"
151 }
152 }</pre> 161 }</pre>
153 <p> 162 <p>
154 If you would like to install extension only for some browser locales, 163 If you would like to install extension only for some browser locales,
155 you can list supported locales in field name "supported_locale". Locale may 164 you can list supported locales in field name "supported_locale". Locale may
156 specify parent locale like "en", in this case the extension will be 165 specify parent locale like "en", in this case the extension will be
157 installed for all English locales like "en-US", "en-GB", etc. 166 installed for all English locales like "en-US", "en-GB", etc.
158 If another browser locale is selected that is not supported by the extension, 167 If another browser locale is selected that is not supported by the extension,
159 the external extensions will be uninstalled. If "supported_locales" list 168 the external extensions will be uninstalled. If "supported_locales" list
160 is missing, the extension will be installed for any locale. 169 is missing, the extension will be installed for any locale.
161 </p> 170 </p>
162 Example: 171 Example:
163 <pre>{ 172 <pre>{
164 "aaaaaaaaaabbbbbbbbbbcccccccccc": { 173 "external_update_url": "http://myhost.com/mytestextension/updates.xml",
165 "external_update_url": "http://myhost.com/mytestextension/updates.xml", 174 "supported_locales": [ "en", "fr", "de" ]
166 "supported_locales": [ "en", "fr", "de" ]
167 }
168 }</pre> 175 }</pre>
169 </li> 176 </li>
170
171 <li>Save the JSON file. </li> 177 <li>Save the JSON file. </li>
172 <li>Launch Google Chrome and go to <b>chrome://extensions</b>; 178 <li>Launch Google Chrome and go to <b>chrome://extensions</b>;
173 you should see the extension listed. </li> 179 you should see the extension listed. </li>
174 </ol> 180 </ol>
175 181
176 <h3 id="troubleshooting">Troubleshooting Mac OS permissions problems</h3> 182 <h3 id="troubleshooting">Troubleshooting Mac OS permissions problems</h3>
177 183
178 <p>On Mac OS, the external extensions file for all users is only read if file sy stem permissions prevent unprivelaged users from changing it. If you do not see external extensions installed when Chrome is launched, there may be a permissio ns problem with the external extensions preferences file. To see if this is the problem, follow these steps:</p> 184 <p>On Mac OS, the external extensions files for all users are only read if file system permissions prevent unprivileged users from changing it. If you do not s ee external extensions installed when Chrome is launched, there may be a permiss ions problem with the external extensions preferences files. To see if this is the problem, follow these steps:</p>
179 185
180 <ol> 186 <ol>
181 <li> Launch the Console program. You can find it under /Applications/Utilitie s/Console. </li> 187 <li> Launch the Console program. You can find it under /Applications/Utilitie s/Console. </li>
182 <li> If the leftmost icon in the Console says "Show Log List", click that icon . A second column appears at the left. </li> 188 <li> If the leftmost icon in the Console says "Show Log List", click that icon . A second column appears at the left. </li>
183 <li> Click "Console Messages" in the left pane. </li> 189 <li> Click "Console Messages" in the left pane. </li>
184 <li> Search for the string <b>Can not read external extensions</b>. If there is a problem reading the external extensions file, you will find an error messag e. Look for another error message directly above it, which should explain the i ssue. For example, if you see the following error: 190 <li> Search for the string <b>Can not read external extensions</b>. If there is a problem reading the external extensions files, you will see an error messag e. Look for another error message directly above it, which should explain the i ssue. For example, if you see the following error:
185 "Path /Library/Application Support/Google/Chrome is owned by the wrong grou p", you need to use <code>chgrp</code> or the Finder's Get Info dialog to change the directory's group owner to the Administrator group.</li> 191 "Path /Library/Application Support/Google/Chrome is owned by the wrong grou p", you need to use <code>chgrp</code> or the Finder's Get Info dialog to change the directory's group owner to the Administrator group.</li>
186 <li> After fixing the issue, relaunch Chrome. Test that the external extensio n is now installed. It is possible that one permissions error keeps Chrome from detecting a second error. If the external extension was not installed, repeat these steps until you do not see an error in the Console application. 192 <li> After fixing the issue, relaunch Chrome. Test that the external extensio n is now installed. It is possible that one permissions error keeps Chrome from detecting a second error. If the external extension was not installed, repeat these steps until you do not see an error in the Console application.
187 </ol> 193 </ol>
188 194
189 <h2 id="registry">Using the Windows registry</h2> 195 <h2 id="registry">Using the Windows registry</h2>
190 196
191 <ol> 197 <ol>
192 <li>Make the <code>.crx</code> extension file available 198 <li>Make the <code>.crx</code> extension file available
193 to the machine you want to install the extension on. 199 to the machine you want to install the extension on.
194 (Copy it to a local directory or to a network share &mdash; 200 (Copy it to a local directory or to a network share &mdash;
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
227 each time the browser starts, and makes 233 each time the browser starts, and makes
228 any necessary changes to the installed 234 any necessary changes to the installed
229 external extensions. </p> 235 external extensions. </p>
230 236
231 <p>To update your extension to a new version, 237 <p>To update your extension to a new version,
232 update the file, and then update the version 238 update the file, and then update the version
233 in the preferences or registry. </p> 239 in the preferences or registry. </p>
234 240
235 <p>To uninstall your extension 241 <p>To uninstall your extension
236 (for example, if your software is uninstalled), 242 (for example, if your software is uninstalled),
237 remove the metadata from the preferences file 243 remove your preference file (aaaaaaaaaabbbbbbbbbbcccccccccc.json)
238 or registry. </p> 244 or the metadata from the registry. </p>
239 245
240 <h2 id="faq">FAQ</h2> 246 <h2 id="faq">FAQ</h2>
241 247
242 <p> 248 <p>
243 This section answers common questions about external extensions. 249 This section answers common questions about external extensions.
244 </p> 250 </p>
245 251
246 <br> 252 <br>
247 253
248 <p><b>Can I specify a URL as a path to the external extension?</b> </p> 254 <p><b>Can I specify a URL as a path to the external extension?</b> </p>
249 <p>Yes, if you use a <a href="#preferences">preferences JSON</a> file. The 255 <p>Yes, if you use a <a href="#preferences">preferences JSON</a> file. The
250 extension must be hosted as explained in <a href="hosting.html">hosting</a>. 256 extension must be hosted as explained in <a href="hosting.html">hosting</a>.
251 Use the "external_update_url" property to point to an 257 Use the "external_update_url" property to point to an
252 <a href="autoupdate.html#H2-2">update manifest</a> that has the URL for your 258 <a href="autoupdate.html#H2-2">update manifest</a> that has the URL for your
253 extension.</p> 259 extension.</p>
254 260
255 <br> 261 <br>
256 262
257 <p><b>What are some common mistakes when installing with the preferences 263 <p><b>What are some common mistakes when installing with the preferences
258 file?</b></p> 264 file?</b></p>
259 <ul> 265 <ul>
260 <li> 266 <li>
261 Not specifying the same id/version 267 Not specifying the same id/version
262 as the one listed in the <code>.crx</code> </li> 268 as the one listed in the <code>.crx</code> </li>
263 <li> 269 <li>
264 <code>external_extensions.json</code> is in the wrong location </li> 270 The .json file (<code>aaaaaaaaaabbbbbbbbbbcccccccccc.json</code>) is in
271 the wrong location or the ID specified does not match the extension ID.
265 <li> 272 <li>
266 Syntax error in JSON file 273 Syntax error in JSON file
267 (forgetting to separate entries with comma or 274 (forgetting to separate entries with comma or
268 leaving a trailing comma somewhere) </li> 275 leaving a trailing comma somewhere) </li>
269 <li> 276 <li>
270 Extra curly brackets around the top level dictionary </li>
271 <li>
272 JSON file entry points to the wrong path 277 JSON file entry points to the wrong path
273 to the <code>.crx</code> (or path specified but no filename) </li> 278 to the <code>.crx</code> (or path specified but no filename) </li>
274 <li> 279 <li>
275 Backslashes in UNC path not escaped 280 Backslashes in UNC path not escaped
276 (for example, <code>"\\server\share\file"</code> is wrong; 281 (for example, <code>"\\server\share\file"</code> is wrong;
277 it should be <code>"\\\\server\\share\\extension"</code>) </li> 282 it should be <code>"\\\\server\\share\\extension"</code>) </li>
278 <li> 283 <li>
279 Permissions problems on a network share </li> 284 Permissions problems on a network share </li>
280 </ul> 285 </ul>
281 286
(...skipping 18 matching lines...) Expand all
300 305
301 <br> 306 <br>
302 307
303 <p><b>How do I get off the blacklist?</b> </p> 308 <p><b>How do I get off the blacklist?</b> </p>
304 <p>If the user uninstalls your extension, you should respect that 309 <p>If the user uninstalls your extension, you should respect that
305 decision. However, if you (the developer) accidentally uninstalled 310 decision. However, if you (the developer) accidentally uninstalled
306 your extension through the UI, 311 your extension through the UI,
307 you can remove the blacklist tag 312 you can remove the blacklist tag
308 by installing the extension normally 313 by installing the extension normally
309 through the UI, and then uninstalling it. </p> 314 through the UI, and then uninstalling it. </p>
OLDNEW
« no previous file with comments | « chrome/common/extensions/docs/external_extensions.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698