Skip to content

docs: add npm copy rfc#493

Open
everett1992 wants to merge 1 commit into
npm:mainfrom
everett1992:npm-copy
Open

docs: add npm copy rfc#493
everett1992 wants to merge 1 commit into
npm:mainfrom
everett1992:npm-copy

Conversation

@everett1992

@everett1992 everett1992 commented Nov 15, 2021

Copy link
Copy Markdown

npm copy <destination> copies the current project's files and dependencies to
destination

When deploying a project (COPY into a docker image, zip into an archive)
non production dependencies and files should be excluded. npm has some commands
that cover this usecase (prune, pack, install -g but they each have
issues, especially when workspaces are used.

# copy app's production dependencies and packaged files to out
npm copy out --production -w app

# copy all workspace production dependencies and packaged files to archive
npm copy out --production --workspaces

See 0000-npm-copy.md

I've written an implementation here npm/cli#4082

@everett1992

Copy link
Copy Markdown
Author

I think this RFC addresses #463 Multi-app Monorepo Support

@bnb

bnb commented Nov 17, 2021

Copy link
Copy Markdown

Seems like a nice command. Just reiterating what I said in the RFC, want to make sure this works well for non-workspace users in addition to workspaces (which it seems to!).

@jeanbmar

jeanbmar commented Feb 8, 2022

Copy link
Copy Markdown

I can't wait for this to land. Packaging workspaces for deployment is a guaranteed headache.

@darcyclarke darcyclarke added the Agenda will be discussed at the Open RFC call label Mar 31, 2022
@darcyclarke darcyclarke removed the Agenda will be discussed at the Open RFC call label Apr 20, 2022
@darcyclarke

Copy link
Copy Markdown
Contributor

Removing Agenda label as we have discussed this work & agree we'd like to see it land. We can ratify this doc at any point here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants