Skip to content
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

docs(deploy): flag and setting for legacy #635

Merged
merged 6 commits into from
Feb 6, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions docs/cli/deploy.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ title: "pnpm deploy"

Deploy a package from a workspace. During deployment, the files of the deployed package are copied to the target directory. All dependencies of the deployed package, including dependencies from the workspace, are installed inside an isolated `node_modules` directory at the target directory. The target directory will contain a portable package that can be copied to a server and executed without additional steps.

:::note

By default, the deploy command only works with workspaces that have the `injected-workspace-dependencies` setting set to `true`. If you want to use deploy without "injected dependencies", use the `--legacy` flag or set `force-legacy-deploy` to `true`.

:::

Usage:

```
Expand Down Expand Up @@ -53,6 +59,12 @@ Packages in `devDependencies` won't be installed.

[Read more about filtering.](../filtering.md)

### --legacy

Force legacy deploy implementation.

By default, `pnpm deploy` will try creating a dedicated lockfile from a shared lockfile for deployment. The `--legacy` flag disables this behavior and also allows using the deploy command without the `injected-workspace-dependencies=true` setting.

## Files included in the deployed project

By default, all the files of the project are copied during deployment but this can be modified in _one_ of the following ways which are resolved in order:
Expand Down
9 changes: 9 additions & 0 deletions docs/npmrc.md
Original file line number Diff line number Diff line change
Expand Up @@ -1019,6 +1019,15 @@ When set to `true`, no workspace cycle warnings will be printed.

When set to `true`, installation will fail if the workspace has cycles.

## Deploy Settings

### force-legacy-deploy

* Default: **false**
* Type: **Boolean**

By default, `pnpm deploy` will try creating a dedicated lockfile from a shared lockfile for deployment. If this setting is set to `true`, the legacy `deploy` behavior will be used.

## Other Settings

### save-prefix
Expand Down
Loading