Skip to content

Commit

Permalink
Merge pull request #6567 from storybooks/tech/opn-to-open
Browse files Browse the repository at this point in the history
CHANGE opn to open
  • Loading branch information
ndelangen committed Apr 19, 2019
2 parents 7a15a14 + 9ea67ad commit c4f5c3f
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 12 deletions.
2 changes: 1 addition & 1 deletion lib/cli/test/fixtures/sfc_vue/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"friendly-errors-webpack-plugin": "^1.7.0",
"html-webpack-plugin": "^4.0.0-beta.2",
"http-proxy-middleware": "^0.19.1",
"opn": "^5.4.0",
"open": "^6.1.0",
"optimize-css-assets-webpack-plugin": "^2.0.0",
"ora": "^3.2.0",
"rimraf": "^2.6.3",
Expand Down
2 changes: 1 addition & 1 deletion lib/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
"json5": "^2.1.0",
"lazy-universal-dotenv": "^2.0.0",
"node-fetch": "^2.3.0",
"opn": "^6.0.0",
"open": "^6.1.0",
"postcss-flexbugs-fixes": "^4.1.0",
"postcss-loader": "^3.0.0",
"pretty-hrtime": "^1.0.3",
Expand Down
8 changes: 5 additions & 3 deletions lib/core/src/server/build-dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { logger, colors, instance as npmLog } from '@storybook/node-logger';
import fetch from 'node-fetch';
import Cache from 'file-system-cache';
import findCacheDir from 'find-cache-dir';
import opn from 'opn';
import open from 'open';
import boxen from 'boxen';
import semver from 'semver';
import { stripIndents } from 'common-tags';
Expand Down Expand Up @@ -219,13 +219,15 @@ function outputStartupInformation(options) {
}

async function outputStats(previewStats, managerStats) {
if (previewStats) await writeStats('preview', previewStats);
if (previewStats) {
await writeStats('preview', previewStats);
}
await writeStats('manager', managerStats);
logger.info(`stats written to => ${chalk.cyan(path.join(cacheDir, '[name].json'))}`);
}

function openInBrowser(address) {
opn(address).catch(() => {
open(address).catch(() => {
logger.error(stripIndents`
Could not open ${address} inside a browser. If you're running this command inside a
docker container or on a CI, you need to pass the '--ci' flag to prevent opening a
Expand Down
14 changes: 7 additions & 7 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -18751,6 +18751,13 @@ open@6.0.0:
dependencies:
is-wsl "^1.1.0"

open@^6.1.0:
version "6.1.0"
resolved "https://registry.yarnpkg.com/open/-/open-6.1.0.tgz#0e7e671b883976a4e5251b5d1ca905ab6f4be78f"
integrity sha512-Vqch7NFb/WsMujhqfq+B3u0xkssRjZlxh+NSsBSphpcgaFD7gfB0SUBfR91E9ygBlyNGNogXR2cUB8rRfoo2kQ==
dependencies:
is-wsl "^1.1.0"

opener@^1.5.1:
version "1.5.1"
resolved "https://registry.yarnpkg.com/opener/-/opener-1.5.1.tgz#6d2f0e77f1a0af0032aca716c2c1fbb8e7e8abed"
Expand Down Expand Up @@ -18787,13 +18794,6 @@ opn@^5.1.0, opn@^5.3.0:
dependencies:
is-wsl "^1.1.0"

opn@^6.0.0:
version "6.0.0"
resolved "https://registry.yarnpkg.com/opn/-/opn-6.0.0.tgz#3c5b0db676d5f97da1233d1ed42d182bc5a27d2d"
integrity sha512-I9PKfIZC+e4RXZ/qr1RhgyCnGgYX0UEIlXgWnCOVACIvFgaC9rz6Won7xbdhoHrd8IIhV7YEpHjreNUNkqCGkQ==
dependencies:
is-wsl "^1.1.0"

optimist@0.6.x, optimist@^0.6.1, optimist@~0.6.0:
version "0.6.1"
resolved "https://registry.yarnpkg.com/optimist/-/optimist-0.6.1.tgz#da3ea74686fa21a19a111c326e90eb15a0196686"
Expand Down

0 comments on commit c4f5c3f

Please sign in to comment.