-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8d8da7b
commit d74aebe
Showing
5 changed files
with
81 additions
and
48 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
7 changes: 7 additions & 0 deletions
7
src/main/java/studio/o7/remora/extensions/DefaultRemoraExtension.java
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,7 @@ | ||
package studio.o7.remora.extensions; | ||
|
||
import org.gradle.api.reflect.HasPublicType; | ||
|
||
public abstract class DefaultRemoraExtension implements RemoraExtension, HasPublicType { | ||
|
||
} |
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
38 changes: 11 additions & 27 deletions
38
src/main/java/studio/o7/remora/extensions/RemoraExtension.java
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 |
---|---|---|
@@ -1,35 +1,19 @@ | ||
package studio.o7.remora.extensions; | ||
|
||
import lombok.Data; | ||
import org.gradle.api.provider.Property; | ||
import org.gradle.api.tasks.Optional; | ||
import org.gradle.jvm.toolchain.JavaLanguageVersion; | ||
|
||
@Data | ||
public class RemoraExtension { | ||
/** | ||
* Project group id. Set as gradle group and publishing groupId. | ||
*/ | ||
private String groupId; | ||
/** | ||
* Project artifact id. Set as publishing artifactId. | ||
*/ | ||
private String artifactId; | ||
/** | ||
* Project description. Set as publishing description. | ||
*/ | ||
private String description; | ||
public interface RemoraExtension { | ||
|
||
/** | ||
* Java language version. | ||
*/ | ||
private JavaLanguageVersion javaVersion = JavaLanguageVersion.of(23); | ||
Property<String> getGroupId(); | ||
|
||
/** | ||
* Configuration of included frameworks. | ||
*/ | ||
private FrameworkExtension framework = new FrameworkExtension(); | ||
Property<String> getArtifactId(); | ||
|
||
@Optional | ||
Property<String> getDescription(); | ||
|
||
@Optional | ||
Property<JavaLanguageVersion> getJavaVersion(); | ||
|
||
/** | ||
* Configuration of publishing strategies. | ||
*/ | ||
private PublishingExtension publishing = new PublishingExtension(); | ||
} |
41 changes: 41 additions & 0 deletions
41
src/main/java/studio/o7/remora/extensions/RemoraOldExtension.java
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,41 @@ | ||
package studio.o7.remora.extensions; | ||
|
||
import lombok.Data; | ||
import org.gradle.api.model.ObjectFactory; | ||
import org.gradle.jvm.toolchain.JavaLanguageVersion; | ||
|
||
@Data | ||
public class RemoraOldExtension { | ||
/** | ||
* Project group id. Set as gradle group and publishing groupId. | ||
*/ | ||
private String groupId; | ||
/** | ||
* Project artifact id. Set as publishing artifactId. | ||
*/ | ||
private String artifactId; | ||
/** | ||
* Project description. Set as publishing description. | ||
*/ | ||
private String description; | ||
|
||
/** | ||
* Java language version. | ||
*/ | ||
private JavaLanguageVersion javaVersion = JavaLanguageVersion.of(23); | ||
|
||
/** | ||
* Configuration of included frameworks. | ||
*/ | ||
private FrameworkExtension framework; | ||
|
||
/** | ||
* Configuration of publishing strategies. | ||
*/ | ||
private PublishingExtension publishing = new PublishingExtension(); | ||
|
||
|
||
public RemoraOldExtension(ObjectFactory factory) { | ||
this.framework = factory.newInstance(FrameworkExtension.class); | ||
} | ||
} |