无法编译,因为它会抛出编译错误

无法执行目标org.apache.maven.plugins:maven-antrun-plugin:1.8:在项目flin-web-core上运行(fixProperties):发生了Ant BuildException:无法替换表达式 . 围绕 Ant 部分...... @ 4:42

<plugin>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-antrun-plugin</artifactId>
    <executions>
        <execution>
            <id>fixProperties</id>
            <phase>generate-sources</phase>
            <goals>
                <goal>run</goal>
            </goals>
            <configuration>
                <tasks>
                    <replaceregexp byline="true" flags="g">
                        <regexp pattern="([^'])'([^'])" />
                        <substitution expression="\1''\2" />
                        <fileset dir="${project.build.directory}/generated-sources"> 
                            <include name="ApplicationResources_*.properties" /> 
                        </fileset>
                    </replaceregexp>
                </tasks>
            </configuration>
        </execution>
    </executions>
</plugin>

堆栈跟踪

org.apache.maven.lifecycle.LifecycleExecutionException:无法执行目标org.apache.maven.plugins:maven-antrun-plugin:1.8:在项目flin-web-core上运行(fixProperties):发生了Ant BuildException:C :\ petprojects \ system \ system \ trunk \ flin-web-core \ target \ generated-sources不存在 . 围绕Ant部分...... @ 4:42在org.apache.maven.lifecycle.internal的C:\ petprojects \ system \ system \ trunk \ flin-web-core \ target \ antrun \ build-main.xml中.MojoExecutor.execute(MojoExecutor.java:216)org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java) :145)在org.apache的org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80) . 在org.apache.maven.maven.DefaultMaven的org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:120)上的maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51) . 在org.apache.maache.maven.maven上的org.apache.maven.maven.MavenCli.execute(MavenCli.java:584)的org.apache.maven.DefaultMaven.execute(DefaultMaven.java:155)执行执行(DefaultMaven.java:355) .cli .MavenCli.doMain(MavenCli.java:216)atg.apache.maven.cli.MavenCli.main(MavenCli.java:160)at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:39)位于org.codehaus.plexus.classworlds.launcher的java.lang.reflect.Method.invoke(Method.java:597)的sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) . Launcher.launchEnhanced(Launcher.java:289)org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java: 415)at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)引起:org.apache.maven.plugin.MojoExecutionException:发生了Ant BuildException:C:\ petprojects \ system \ system \ trunk \ flin-web-core \ target \ generated-sources不存在 . 围绕Ant部分...... @ 4:42在org.apache.maven.plugin.antrun的C:\ petprojects \ system \ system \ trunk \ flin-web-core \ target \ antrun \ build-main.xml中.AntRunMojo.execute(AntRunMojo.java:342)org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:132)org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208) )... 19更多引起:C:\ petprojects \ system \ system \ trunk \ glin-web-core \ target \ antrun \ build-main.xml:4:C:\ petprojects \ system \ system \ trunk \ glin -web-core \ target \ generated-sources不存在 . org.apache.tools.ant.types.AbstractFileSet.getDirectoryScanner(AbstractFileSet.java:484)位于org.apache.tools.ant的org.apache.tools.ant.types.FileSet.iterator(FileSet.java:69)位于org.apache.tools.ant.types.resources的org.apache.tools.ant.types.resources.Union.getCollection(Union.java:108)的.types.resources.Union.getAllResources(Union.java:148) .baseResourceCollectionContainer.cacheCollection(BaseResourceCollectionContainer.java:263)位于org.apache.tools.ant.taskdefs.optional.ReplaceRegExp.execute的org.apache.tools.ant.types.resources.BaseResourceCollectionContainer.iterator(BaseResourceCollectionContainer.java:142) (replaceRegExp.java:548)atg.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java) :39)at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)at java.lang.reflect.Method.invoke(Method.ja va:597)org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)位于org.apache.tools的org.apache.tools.ant.Task.perform(Task.java:348) .ant.Target.execute(Target.java:435)org.apache.tools.ant.Target.performTasks(Target.java:456)org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393) ) 在org.apache.tools.ant.Project.executeTarget(Project.java:1364)atg.apache.maven.plugin.antrun.AntRunMojo.execute(AntRunMojo.java:313)... 21更多[错误] [错误] [错误]有关错误和可能的解决方案的更多信息,请阅读以下文章:[错误] [帮助1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException [ERROR] [ERROR]之后纠正问题,您可以使用命令[ERROR] mvn -rf:flin-web-core恢复构建