eirslett / frontend-maven-plugin

"Maven-node-grunt-gulp-npm-node-plugin to end all maven-node-grunt-gulp-npm-plugins." A Maven plugin that downloads/installs Node and NPM locally, runs NPM install, Grunt, Gulp and/or Karma.
Apache License 2.0
4.25k stars 870 forks source link

Npm log is not displayed in the maven log #791

Open Bratchvv opened 5 years ago

Bratchvv commented 5 years ago

Hello. When I building a project with maven, the log of execution npm scripts is not displayed.

Output only the gulp log.

Execution of all scripts is successful.

Should these logs be displayed?

Here my pom:

<plugin>
    <groupId>com.github.eirslett</groupId>
    <artifactId>frontend-maven-plugin</artifactId>
    <version>1.6</version>
    <configuration>
        <installDirectory>${angular.project.nodeinstallation}</installDirectory>
    </configuration>
    <executions>
        <!-- It will install nodejs and npm -->
        <execution>
            <id>install node and npm</id>
            <goals>
                <goal>install-node-and-npm</goal>
            </goals>
            <configuration>
                <nodeVersion>v10.13.0</nodeVersion>
                <npmVersion>6.4.1</npmVersion>
            </configuration>
        </execution>
        <execution>
            <id>npm install</id>
            <goals>
                <goal>npm</goal>
            </goals>
            <configuration>
                <arguments>install</arguments>
            </configuration>
        </execution>
        <execution>
            <id>npm install tslint</id>
            <goals>
                <goal>npm</goal>
            </goals>
            <configuration>
                <arguments>install tslint-config-airbnb --save-dev</arguments>
            </configuration>
        </execution>
        <execution>
            <id>npm build</id>
            <goals>
                <goal>npm</goal>
            </goals>
            <configuration>
                <arguments>run build:prod</arguments>
            </configuration>
        </execution>
    </executions>
</plugin>

Here me LOG OUTPUT sample

INFO org.apache.maven.cli.event.ExecutionEventLogger - --- frontend-maven-plugin:1.6:npm (npm build) INFO com.github.eirslett.maven.plugins.frontend.lib.DefaultNpmRunner - Running 'npm run build:prod' in ... INFO com.github.eirslett.maven.plugins.frontend.lib.DefaultNpmRunner - INFO com.github.eirslett.maven.plugins.frontend.lib.DefaultNpmRunner - > gulp preBuild & ng build --base-href / --prod --aot --build-optimizer & gulp postBuild INFO com.github.eirslett.maven.plugins.frontend.lib.DefaultNpmRunner - INFO com.github.eirslett.maven.plugins.frontend.lib.DefaultNpmRunner - Using gulpfile .../gulpfile.js INFO com.github.eirslett.maven.plugins.frontend.lib.DefaultNpmRunner - Starting 'preBuild'... INFO com.github.eirslett.maven.plugins.frontend.lib.DefaultNpmRunner - Finished 'preBuild' after 17 ms INFO com.github.eirslett.maven.plugins.frontend.lib.DefaultNpmRunner - Using gulpfile .../gulpfile.js ======= HERE MUST BE MORE LOGS ====== INFO com.github.eirslett.maven.plugins.frontend.lib.DefaultNpmRunner - Starting 'postBuild'... INFO com.github.eirslett.maven.plugins.frontend.lib.DefaultNpmRunner - Finished 'postBuild' after 17 ms

Please help me understand and fix this problem.

mgodu01 commented 5 years ago

same here

eirslett commented 5 years ago

Yes, everything should be logged more or less directly. Can you try a version of the plugin that is a bit older? I think, if you check the changelog, that there has been some changes that hide certain elements from the log. It might have introduced a bug.

raDiesle commented 4 years ago

For me we realized first time switching from 1.7.6 to 1.9.1