-
Notifications
You must be signed in to change notification settings - Fork 72
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Pass in single recipe configuration options on the command line (#816)
* Made possible to configure options on recipes * Polish logged message for printed data tables * Fail to configure recipes containing other recipes * Only parse flat options, with limited external dependencies * Unpack CompositeRecipe containing single recipe Due to https://github.com/openrewrite/rewrite/blob/ec09e19feba2ccff12cc20d0d684babde9aa7914/rewrite-core/src/main/java/org/openrewrite/config/Environment.java#L163 * Unit test handling of arguments * Use a LinkedHashSet<String> for options * Apply suggestions from code review * Alter check for no recipe found --------- Co-authored-by: Tim te Beek <tim@moderne.io> Co-authored-by: Tim te Beek <timtebeek@gmail.com>
- Loading branch information
1 parent
03dea00
commit 7ecc255
Showing
3 changed files
with
122 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
src/test/resources-its/org/openrewrite/maven/RewriteRunIT/command_line_options/pom.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xmlns="http://maven.apache.org/POM/4.0.0" | ||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
<modelVersion>4.0.0</modelVersion> | ||
|
||
<groupId>org.openrewrite.maven</groupId> | ||
<artifactId>command_line_options</artifactId> | ||
<version>1.0</version> | ||
<packaging>jar</packaging> | ||
<name>RewriteRunIT#command_line_options</name> | ||
|
||
<properties> | ||
<maven.compiler.source>1.8</maven.compiler.source> | ||
<maven.compiler.target>1.8</maven.compiler.target> | ||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> | ||
</properties> | ||
|
||
<build> | ||
<plugins> | ||
<plugin> | ||
<groupId>@project.groupId@</groupId> | ||
<artifactId>@project.artifactId@</artifactId> | ||
<version>@project.version@</version> | ||
</plugin> | ||
</plugins> | ||
</build> | ||
</project> |