我'新ANTLR4,似乎没有Eclipse的插件,V4。 因此,这将很好的自动构建从.g4语法的Java源代码。 我有一个简单的,空的Maven项目用的src / main / java中,SRC /测试/ java中。 在何处放置.g4文件? 我怎么能自动用Maven构建这个语法?
我自己的POM-测试失败:
<repository>
<id>mvn-public</id>
<name>MVNRepository</name>
<url>http://mvnrepository.com</url>
</repository>
...
<build>
<plugins>
<plugin>
<groupId>org.antlr</groupId>
<artifactId>antlr4-maven-plugin</artifactId>
<version>4.0.0</version>
<executions>
<execution>
<goals>
<goal>antlr</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
Eclipse中说:
Failure to find org.antlr:antlr4-maven-plugin:pom:4.0.0 in http://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of
central has elapsed or updates are forced