From 47f99d65a09660863cb5d6b25b239ead3389f3ac Mon Sep 17 00:00:00 2001 From: Thibault Gagnaux Date: Wed, 2 Feb 2022 18:50:13 +0100 Subject: feat: simplifies the whole gradle plugin - the `compileFregeTask` has a new optional input called `mainModuleName`. If it is set, it and only its dependencies will be compiled, otherwise all `.fr`files in the `mainSourceDir`will be compiled. - the internal `DependencyFregeTask` is deleted because it was only used by the vscode plugin and I decided to remove this gradle plugin as a dependency. - an example project folder was added to test the plugin manually. --- .../internal/DependencyFregeTask.java | 41 ---------------------- 1 file changed, 41 deletions(-) delete mode 100644 src/main/java/ch/fhnw/thga/gradleplugins/internal/DependencyFregeTask.java (limited to 'src/main/java/ch/fhnw/thga/gradleplugins/internal/DependencyFregeTask.java') diff --git a/src/main/java/ch/fhnw/thga/gradleplugins/internal/DependencyFregeTask.java b/src/main/java/ch/fhnw/thga/gradleplugins/internal/DependencyFregeTask.java deleted file mode 100644 index 87f4d2b..0000000 --- a/src/main/java/ch/fhnw/thga/gradleplugins/internal/DependencyFregeTask.java +++ /dev/null @@ -1,41 +0,0 @@ -package ch.fhnw.thga.gradleplugins.internal; - -import org.gradle.api.DefaultTask; -import org.gradle.api.file.DirectoryProperty; -import org.gradle.api.file.RegularFileProperty; -import org.gradle.api.provider.Property; -import org.gradle.api.tasks.Input; -import org.gradle.api.tasks.InputDirectory; -import org.gradle.api.tasks.InputFile; -import org.gradle.api.tasks.TaskAction; -import org.gradle.api.tasks.options.Option; - -import ch.fhnw.thga.gradleplugins.SharedTaskLogic; - -public abstract class DependencyFregeTask extends DefaultTask { - @InputFile - public abstract RegularFileProperty getFregeCompilerJar(); - - @Input - public abstract Property getFregeDependencies(); - - @InputDirectory - public abstract DirectoryProperty getFregeOutputDir(); - - @Input - @Option(option = "replSource", - description = "The filename which you want to load into the repl, e.g. 'myFregeFile.fr'") - public abstract Property getReplSource(); - - - @TaskAction - public void fregeDependencies() { - System.out.println( - SharedTaskLogic.setupClasspath( - getProject(), - getFregeDependencies(), - getFregeCompilerJar(), - getFregeOutputDir()) - .get().getAsPath()); - } -} -- cgit