mmizutani / sbt-play-gulp

Gulp asset pipeline for Play Framework
Other
37 stars 12 forks source link

bad option: --force with node 10 and npm 6.1 #31

Closed almothafar closed 6 years ago

almothafar commented 6 years ago

I can't make my application run when I do sbt clean update compile it stop in the following error:

C:\Program Files\nodejs\node.exe: bad option: --force
[error] java.io.IOException: [cmd, /c, node, D:\Sources\MyProject\ui\node_modules\gulp\bin\gulp.js, --gulpfile=gulpfile.js, clean, --force] in D:\Sources\MyProject\ui failed with exit code 9
[error]         at com.github.mmizutani.sbt.gulp.PlayGulpPlugin$.com$github$mmizutani$sbt$gulp$PlayGulpPlugin$$runGulp(PlayGulpPlugin.scala:175)
[error]         at com.github.mmizutani.sbt.gulp.PlayGulpPlugin$.$anonfun$playGulpSettings$15(PlayGulpPlugin.scala:76)
[error]         at com.github.mmizutani.sbt.gulp.PlayGulpPlugin$.$anonfun$playGulpSettings$15$adapted(PlayGulpPlugin.scala:72)
[error]         at scala.Function1.$anonfun$compose$1(Function1.scala:44)
[error]         at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:39)
[error]         at sbt.std.Transform$$anon$4.work(System.scala:66)
[error]         at sbt.Execute.$anonfun$submit$2(Execute.scala:263)
[error]         at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error]         at sbt.Execute.work(Execute.scala:272)
[error]         at sbt.Execute.$anonfun$submit$1(Execute.scala:263)
[error]         at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:174)
[error]         at sbt.CompletionService$$anon$2.call(CompletionService.scala:37)
[error]         at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error]         at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[error]         at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error]         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[error]         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[error]         at java.lang.Thread.run(Thread.java:748)
[error] (gulpClean) java.io.IOException: [cmd, /c, node, D:\Sources\MyProject\ui\node_modules\gulp\bin\gulp.js, --gulpfile=gulpfile.js, clean, --force] in D:\Sources\MyProject\ui failed with exit code 9

Using play 2.6 and this plugin version is 0.2.0


The error even happening with the old version, 2.5.x and 0.1.5

almothafar commented 6 years ago

@mmizutani any idea about this?

mmizutani commented 6 years ago

You can remove the option by adding gulpForce := false to the settings of your Play project.

almothafar commented 6 years ago

@mmizutani thanks, I'll try that and close issue once it is solved.