-
-
Notifications
You must be signed in to change notification settings - Fork 9.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Yarn workspaces #1810
Yarn workspaces #1810
Changes from 15 commits
4d10a55
adb20c6
dc0bd90
2486947
b4d9ee0
d22f209
cd7472a
51363c2
78a42a8
2308e98
fee27b5
6d37521
d846b0c
5d8e07e
75b0076
181878d
cc9ab25
5382fcb
8df6f4d
fe9ee4e
38011e8
f343861
f3046d5
824bbd6
11298bf
088c5f8
bd31e8b
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env node | ||
|
||
require('../dist/server/build'); |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env node | ||
|
||
require('../dist/server'); |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,3 @@ | ||
#!/usr/bin/env node | ||
|
||
import webpack from 'webpack'; | ||
import program from 'commander'; | ||
import path from 'path'; | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env node | ||
|
||
require('../dist/server/build'); |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env node | ||
|
||
require('../dist/server'); |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,3 @@ | ||
#!/usr/bin/env node | ||
|
||
import webpack from 'webpack'; | ||
import program from 'commander'; | ||
import path from 'path'; | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,15 @@ | ||
{ | ||
"lerna": "2.0.0", | ||
"npmClient": "yarn", | ||
"useWorkspaces": true, | ||
"commands": { | ||
"bootstrap": { | ||
"ignore": [ | ||
"crna-kitchen-sink", | ||
"react-native-vanilla" | ||
] | ||
}, | ||
"publish": { | ||
"ignore": [ | ||
"cra-kitchen-sink", | ||
"crna-kitchen-sink", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @Hypnosphi we don't need these because ... "private: true" in package.json? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
"react-native-vanilla", | ||
"vue-example" | ||
"vue-kitchen-sink" | ||
] | ||
} | ||
}, | ||
"packages": [ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @Hypnosphi why don't we need this anymore? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. https://github.com/lerna/lerna#--use-workspaces
|
||
"addons/*", | ||
"app/*", | ||
"lib/*", | ||
"examples/*" | ||
], | ||
"concurrency": 1, | ||
"version": "3.3.0-alpha.0" | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,22 @@ | ||
{ | ||
"private": true, | ||
"name": "storybook", | ||
"version": "3.0.0", | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/storybooks/storybook.git" | ||
}, | ||
"workspaces": [ | ||
"addons/*", | ||
"app/*", | ||
"lib/*", | ||
"examples/cra-kitchen-sink", | ||
"examples/vue-kitchen-sink" | ||
], | ||
"scripts": { | ||
"bootstrap": "./scripts/bootstrap.js", | ||
"bootstrap:core": "lerna bootstrap --concurrency 1 --npm-client=\"yarn\" --hoist && node ./scripts/hoist-internals.js", | ||
"bootstrap:docs": "cd docs && yarn install", | ||
"bootstrap:core": "yarn install && lerna run prepublish && node ./scripts/hoist-internals.js", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Unfortunately, at the moment yarn doesn't run lifecycle hooks when bootstrapping workspaces: yarnpkg/yarn#3911 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We can probably now remove |
||
"bootstrap:docs": "yarn install --cwd docs", | ||
"bootstrap:react-native-vanilla": "npm --prefix examples/react-native-vanilla install", | ||
"bootstrap:crna-kitchen-sink": "npm --prefix examples/crna-kitchen-sink install", | ||
"build-packs": "lerna exec --scope '@storybook/*' --parallel -- ../../scripts/build-pack.sh ../../packs", | ||
|
@@ -23,7 +31,7 @@ | |
"docs:deploy:manual": "cd docs && npm run deploy:manual", | ||
"docs:dev": "cd docs && npm run dev", | ||
"github-release": "github-release-from-changelog", | ||
"lint": "npm run lint:js . && npm run lint:md .", | ||
"lint": "yarn lint:js . && yarn lint:md .", | ||
"lint:js": "eslint --cache --cache-location=.cache/eslint --ext .js,.jsx,.json", | ||
"lint:md": "remark", | ||
"publish": "lerna publish", | ||
|
@@ -80,7 +88,8 @@ | |
"symlink-dir": "^1.1.0" | ||
}, | ||
"engines": { | ||
"node": "node" | ||
"node": "^8.0.0", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This just states the limitation we have de facto |
||
"yarn": "^1.0.0-0" | ||
}, | ||
"collective": { | ||
"type": "opencollective", | ||
|
@@ -89,11 +98,11 @@ | |
"lint-staged": { | ||
"linters": { | ||
"*.js": [ | ||
"npm run lint:js -- --fix", | ||
"yarn lint:js --fix", | ||
"git add" | ||
], | ||
"*.json": [ | ||
"npm run lint:js -- --fix", | ||
"yarn lint:js --fix", | ||
"git add" | ||
], | ||
"*.md": [ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Unfortunately when I try to use yarn for There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change is needed because yarn needs some files to link as binaries, see https://github.com/storybooks/storybook/pull/1810/files#r137413061