Skip to content

Commit 8eaebc3

Browse files
committed
fix: build-prod-ui deps before build-prod packages
1 parent 651b91b commit 8eaebc3

File tree

5 files changed

+10
-4
lines changed

5 files changed

+10
-4
lines changed

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"binary-upload": "node ./scripts/binary.js upload",
1414
"binary-zip": "node ./scripts/binary.js zip",
1515
"build": "lerna run build --stream --no-bail --ignore create-cypress-tests && lerna run build --stream --scope create-cypress-tests",
16-
"build-prod": "lerna run build-prod --stream --ignore create-cypress-tests && lerna run build-prod --stream --scope create-cypress-tests",
16+
"build-prod": "lerna run build-prod-ui --stream && lerna run build-prod --stream --ignore create-cypress-tests && lerna run build-prod --stream --scope create-cypress-tests",
1717
"bump": "node ./scripts/binary.js bump",
1818
"check-node-version": "node scripts/check-node-version.js",
1919
"check-terminal": "node scripts/check-terminal.js",

packages/app/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"private": true,
55
"scripts": {
66
"check-ts": "vue-tsc --noEmit",
7-
"build-prod": "cross-env NODE_ENV=production vite build",
7+
"build-prod-ui": "cross-env NODE_ENV=production vite build",
88
"clean": "rimraf dist && rimraf ./node_modules/.vite && echo 'cleaned'",
99
"clean-deps": "rimraf node_modules",
1010
"test": "echo 'ok'",

packages/launchpad/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"private": true,
55
"scripts": {
66
"check-ts": "vue-tsc --noEmit",
7-
"build-prod": "cross-env NODE_ENV=production vite build",
7+
"build-prod-ui": "cross-env NODE_ENV=production vite build",
88
"clean": "rimraf dist && rimraf ./node_modules/.vite && rimraf dist-e2e && echo 'cleaned'",
99
"clean-deps": "rimraf node_modules",
1010
"test": "yarn cypress:run:ct && yarn types",

scripts/binary/build.js

+4-1
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,10 @@ const buildCypressApp = function (platform, version, options = {}) {
113113
const buildPackages = function () {
114114
log('#buildPackages')
115115

116-
return packages.runAllBuild()
116+
return packages.runAllBuildUI().then(() => {
117+
return packages.runAllBuild()
118+
})
119+
117120
// Promise.resolve()
118121
.then((val) => {
119122
logBuiltAllPackages(val)

scripts/binary/util/packages.js

+3
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ const createCLIExecutable = (command) => {
5050
const yarn = createCLIExecutable('yarn')
5151
const npx = createCLIExecutable('npx')
5252

53+
const runAllBuildUI = _.partial(npx, ['lerna', 'run', 'build-prod-ui'])
5354
const runAllBuild = _.partial(npx, ['lerna', 'run', 'build-prod', '--ignore', 'cli'])
5455

5556
// removes transpiled JS files in the original package folders
@@ -271,6 +272,8 @@ const npmInstallAll = function (pathToPackages) {
271272
}
272273

273274
module.exports = {
275+
runAllBuildUI,
276+
274277
runAllBuild,
275278

276279
copyAllToDist,

0 commit comments

Comments
 (0)