forked from OctoLinker/OctoLinker
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
package.json: Add
chrome-open
script (OctoLinker#247)
Like the `firefox-open` script, this builds and loads the extension into an isolated instance of Chrome, using [chrome-launch]. This has a couple of benefits: 1. New developers can get up-and-running faster 2. It's easier to test Chrome without any other user settings One caveat so far is that Chrome opens in the background rather than the foreground, but this is alleviated by printing a message out informing the developer. [chrome-launch]: https://github.com/hughsk/chrome-launch
- Loading branch information
1 parent
78c5877
commit 4c78d4a
Showing
4 changed files
with
58 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#!/usr/bin/env node | ||
|
||
const chromeLaunch = require('chrome-launch'); // eslint-disable-line import/no-extraneous-dependencies | ||
|
||
const url = 'https://github.com/OctoLinker/browser-extension/blob/master/package.json'; | ||
const args = ['--load-extension=./dist']; | ||
|
||
chromeLaunch(url, { args }); | ||
console.log('A new instance of Chrome should now be open in the background.'); // eslint-disable-line no-console |