ng build --watch: Do not fail when output directory cannot be removed #6434
Labels
feature
Issue that requests a new feature
P5
The team acknowledges the request but does not plan to address it, it remains open for discussion
severity2: inconvenient
Bug Report or Feature Request (mark with an
x
)Versions.
@angular/cli: 1.0.4
node: 6.10.0
os: win32 x64
@angular/common: 4.0.3
@angular/compiler: 4.0.3
@angular/core: 4.0.3
@angular/forms: 4.0.3
@angular/http: 4.0.3
@angular/platform-browser: 4.0.3
@angular/platform-browser-dynamic: 4.0.3
@angular/router: 4.0.3
@angular/cli: 1.0.4
@angular/compiler-cli: 4.0.3
Repro steps.
The log given by the failure.
Desired functionality.
I would like
build --watch
to write directly to my JEE application server so I don't need to redeploy the whole application after small changes in its Angular part.Currently,
build --watch
tries to remove the output directory before compilation starts. The removal fails because output directory contains non-Angular files which are opened by application server. Responsible code is intasks/build.js
, a line likerimraf.sync(path.resolve(project.root, outputPath));
A workaround I use now is to have output directory within my project and use other tool to synchronize it with application server. But of course, it would be nice to have this issue handled in angular/cli.
An example solution could be to add an option for not removing/cleaning the output directory.
Mention any other details that might be useful.
The text was updated successfully, but these errors were encountered: