Skip to content

Commit 3da6100

Browse files
leomotystefanbuck
authored andcommitted
Fix yarn chrome-open to run in Windows (OctoLinker#508)
Fixes OctoLinker#507, unsure if you want to keep these *-open around, but in Windows the relative dir is not resolved. ### Checklist: - [ ] If this PR is a new feature, please provide at least one example link - [ ] Make sure all of the significant new logic is covered by tests
1 parent 7daf942 commit 3da6100

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

scripts/chrome-launch.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
11
#!/usr/bin/env node
22

33
const chromeLaunch = require('chrome-launch'); // eslint-disable-line import/no-extraneous-dependencies
4+
const path = require('path');
45

56
const url = 'https://github.com/OctoLinker/OctoLinker/blob/master/package.json';
6-
const args = ['--load-extension=./dist'];
7+
const dist = path.resolve(__dirname, '..', 'dist');
8+
const args = [`--load-extension=${dist}`];
79

810
chromeLaunch(url, { args });
911
console.log('A new instance of Chrome should now be open in the background.'); // eslint-disable-line no-console

0 commit comments

Comments
 (0)