"lerna run build" fails on components
madrus opened this issue · 1 comments
madrus commented
It would be great if lerna run build
command succeeded. But the build fails on components
package because it misses index.html
file in the public
subfolder. See the command output:
$ lerna run --scope @project/components build
info cli using local version of lerna
lerna notice cli v3.16.1
lerna info filter [ '@project/components' ]
lerna info Executing command in 1 package: "yarn run build"
lerna ERR! yarn run build exited 1 in '@project/components'
lerna ERR! yarn run build stdout:
yarn run v1.17.3
$ react-scripts build
Yarn Workspaces paths detected.
Found 2 path(s) with "main:src" entry.
Exporting Workspaces config to Webpack.
{
root: 'C:\\src\\workspaces\\react-workspaces-playground',
paths: [],
packageEntry: 'main:src',
development: true,
production: true
}
Could not find a required file.
Name: index.html
Searched in: C:\src\workspaces\react-workspaces-playground\packages\components\public
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
lerna ERR! yarn run build stderr:
error Command failed with exit code 1.
lerna ERR! yarn run build exited 1 in '@project/components'
F1LT3R commented
Thank you for pointing this out @madrus !
This should be working now:
d026eac
Rather than add an unused .html
file - which is not relevant for the components, I have removed the build
and start
scripts from packages/components/package.json
.
lerna run build
# ...now passes successfully, building only the apps.