Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/eclipse/9.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Eclipse 使用build helper maven附加源目录_Eclipse_Maven_Build Helper Maven Plugin - Fatal编程技术网

Eclipse 使用build helper maven附加源目录

Eclipse 使用build helper maven附加源目录,eclipse,maven,build-helper-maven-plugin,Eclipse,Maven,Build Helper Maven Plugin,我尝试使用buildhelpermaven插件在中附加由jaxb或cxf生成的源目录。不幸的是,尽管我在mvn生成源代码方面取得了成功,但我的eclipse没有将目标目录添加为源文件夹 <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>build-helper-maven-plugin</artifactId>

我尝试使用buildhelpermaven插件在中附加由jaxb或cxf生成的源目录。不幸的是,尽管我在mvn生成源代码方面取得了成功,但我的eclipse没有将目标目录添加为源文件夹

<plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>build-helper-maven-plugin</artifactId>
            <version>3.0.0</version>
            <executions>
                <execution>
                    <id>add-source</id>
                    <phase>generate-sources</phase>
                    <goals>
                        <goal>add-source</goal>
                    </goals>
                    <configuration>
                        <sources>
                            <source>${project.build.directory}/generated/cxf</source>
                        </sources>
                    </configuration>
                </execution>
            </executions>
        </plugin>
你知道吗


向您致意

Eclipse的M2插件将更好地解释
构建
部分中的声明。试试这个:

<build>
    <sourceDirectory>${project.build.directory}/generated/cxf</sourceDirectory>
</build>

${project.build.directory}/generated/cxf
<build>
    <sourceDirectory>${project.build.directory}/generated/cxf</sourceDirectory>
</build>