JHipster Eclipse Plugin Error

。_饼干妹妹 提交于 2020-01-05 11:52:05

问题


I am trying jhipster demo application but when import project in eclipse i am getting below error in pom.xml file

Plugin execution not covered by lifecycle configuration: com.github.trecloux:yeoman-maven-plugin:0.4:build 
 (execution: run-grunt, phase: generate-resources)

Plugin execution not covered by lifecycle configuration: org.jacoco:jacoco-maven-plugin:
 0.7.4.201502262128:prepare-agent (execution: pre-unit-tests, phase: initialize)

i have tried this link, but its now working for me then I have added below to pom

  <pluginManagement>
        <plugins>
            <!--This plugin's configuration is used to store Eclipse m2e settings only.
                It has no influence on the Maven build itself.-->
            <plugin>
                <groupId>org.eclipse.m2e</groupId>
                <artifactId>lifecycle-mapping</artifactId>
                <version>1.0.0</version>
                <configuration>
                    <lifecycleMappingMetadata>
                        <pluginExecutions>
                            <pluginExecution>
                                <pluginExecutionFilter>
                                    <groupId>org.jacoco</groupId>
                                    <artifactId>jacoco-maven-plugin</artifactId>
                                    <versionRange>[0.5,)
                                    </versionRange>
                                    <goals>
                                        <goal>prepare-agent</goal>
                                    </goals>
                                </pluginExecutionFilter>
                                <action>
                                    <!-- m2e doesn't know what to do with jacoco,
                                        let's ignore it or annoying error markers appear
                                        see http://wiki.eclipse.org/M2E_plugin_execution_not_covered
                                     -->
                                    <ignore></ignore>
                                </action>
                            </pluginExecution>
                             <pluginExecution>
                                <pluginExecutionFilter>
                                    <groupId>
                                        com.github.trecloux
                                    </groupId>
                                    <artifactId>
                                        yeoman-maven-plugin
                                    </artifactId>
                                    <versionRange>
                                        [0.4,)
                                    </versionRange>
                                    <goals>
                                        <goal>build</goal>
                                    </goals>
                                </pluginExecutionFilter>
                                <action>
                                    <ignore></ignore>
                                </action>
                            </pluginExecution>
                        </pluginExecutions>
                    </lifecycleMappingMetadata>
                </configuration>
            </plugin>


        </plugins>
    </pluginManagement>

after that i need to run grunt on command line, The project is started successfully. I am not aware about the impact of disabling the plugins (apart from auto starting grunt server)

Can someone please help to resolve this error ? so i dont need to use command line. I am using Latest Version of Eclipse (Mars), Lastest Maven,yo,grunt,bower.


回答1:


Replace the jacoco version part in pom.xml with the following it will work. I too faced the same issue and resolved with this and is working fine now.

<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>0.7.5.201505241946</version>

So delete the content in between version tags and replace that with .7.5.201505241946. It will work.



来源:https://stackoverflow.com/questions/32998647/jhipster-eclipse-plugin-error

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!