Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
clp-package: Add log-viewer-webui as a component. #476
clp-package: Add log-viewer-webui as a component. #476
Changes from 2 commits
812e5fa
cedf6d3
e02f4a6
99c5872
f5bbb44
89b7854
01d502c
ddbf688
614d6b0
aad6068
9943627
55a7453
e602f15
c97816b
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
We should probably add the
--production
flag to prevent installations of the devDependencies.With that said, I didn't find the related description on the https://docs.npmjs.com/cli/v10/commands/npm-ci page. If the flag is
npm install
specific, we shall explore the--omit
or--include
options.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.
Looking at the specification, if
NODE_ENV
is set to production, both npm install and npm clean-install will not install dev dependencies (here).We can set NODE_ENV in the task to achieve this, but it also make sense to use the omit flag explicitly. let me know what do you think.
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.
Good point. I'm fine with both the NODE_ENV and "--production" approches. For consistency with our other Node.js commands, the NODE_ENV approach seems better.
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.
e.g., (not tested)
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.
in my experiment, I have noticed that building the client first in the repo has cause pycharm and vscode to get confused on the newly generated files.
This step only copies the files to under build/ (instead of build/clp_package), so it does not violate "copy only the generated assets to the clp-package.", so I would still prefer my original approach. I can update it to not copy .env file
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.
Right, sorry for misreading that. It makes sense to copy the sources to the clp/build directory first. We just need to avoid packaging the .env file then.