我想使用OpenRewrite插件和以下链接的方法执行从Java8到Jave 11的源代码迁移:https://docs.openrewrite.org/reference/recipes/java/migrate/java8tojava11 .
正如指南所建议的,我已经向父pom添加了插件指令来迁移代码:
<project>
<build>
<plugins>
<plugin>
<groupId>org.openrewrite.maven</groupId>
<artifactId>rewrite-maven-plugin</artifactId>
<version>4.41.0</version>
<configuration>
<activeRecipes>
<recipe>org.openrewrite.java.migrate.Java8toJava11</recipe>
</activeRecipes>
</configuration>
<dependencies>
<dependency>
<groupId>org.openrewrite.recipe</groupId>
<artifactId>rewrite-migrate-java</artifactId>
<version>1.17.1</version>
</dependency>
</dependencies>
</plugin>
</plugins>
</build>
</project>
我已经执行了mvn目标,但是运行停止并显示以下消息:
The contents of a quark are unknown, so the charset is unknown.
该项目是一个多模块的项目,使用的文件编码是ISO-8859-1。
1条答案
按热度按时间j8ag8udp1#
这个问题是fixed with this code change,在rewrite-maven-plugin v4.41.1中发布的。感谢您引起我们的注意!