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

nx build with --deleteOutputPath causes "Unknown option: '--deleteOutputPath'" #4015

Closed
KirillMetrik opened this issue Nov 3, 2020 · 3 comments · Fixed by #4460
Closed
Labels
community This is a good first issue for contributing outdated scope: react Issues related to React support for Nx type: bug

Comments

@KirillMetrik
Copy link
Contributor

KirillMetrik commented Nov 3, 2020

Current Behavior

running nx build <project_name> --deleteOutputPath=false causes the following error from Angular CLI:
Unknown option: '--deleteOutputPath'

I have tried to create a ticket regarding this in Angular Github: angular/angular-cli#19283 . But they told me this is an NX issue.

Expected Behavior

The build should run.

In version 9 of the whole environment deleteOutputPath was false by default, so it wasn't needed to build with this parameter. Since Angular 10 deleteOutputPath is true by default. We need to preserve an output path because we sometimes have an extra step copying some resources to it before the build.

Steps to Reproduce

The problem can be reproduced on https://github.com/nrwl/nx-examples:

  1. clone nx-examples
  2. run npm install
  3. run nx build cart --deleteOutputPath=false

Environment

nx : Not Found
  @nrwl/angular : 10.3.1-beta.1
  @nrwl/cli : 10.3.1-beta.1
  @nrwl/cypress : 10.3.1-beta.1
  @nrwl/eslint-plugin-nx : Not Found
  @nrwl/express : Not Found
  @nrwl/jest : 10.3.1-beta.1
  @nrwl/linter : 10.3.1-beta.1
  @nrwl/nest : Not Found
  @nrwl/next : Not Found
  @nrwl/node : Not Found
  @nrwl/react : 10.3.1-beta.1
  @nrwl/schematics : Not Found
  @nrwl/tao : 10.3.1-beta.1
  @nrwl/web : 10.3.1-beta.1
  @nrwl/workspace : 10.3.1-beta.1
  typescript : 4.0.3
@KirillMetrik
Copy link
Contributor Author

Any reaction to this please? @vsavkin ?

@FrozenPandaz FrozenPandaz added the scope: react Issues related to React support for Nx label Nov 6, 2020
@FrozenPandaz
Copy link
Collaborator

We do not currently support that option and we always remove the output directory. I think it is a good option to have. Would someone like to add that option?

@FrozenPandaz FrozenPandaz added the community This is a good first issue for contributing label Nov 6, 2020
bekos added a commit to bekos/nx that referenced this issue Jan 7, 2021
vsavkin pushed a commit that referenced this issue Jan 7, 2021
@github-actions
Copy link

This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
community This is a good first issue for contributing outdated scope: react Issues related to React support for Nx type: bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants