diff options
author | tricktron <tgagnaux@gmail.com> | 2021-11-10 09:36:14 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-11-10 09:36:14 +0100 |
commit | 5df7fd223a84c2c4db55668da2b5c0f460a19774 (patch) | |
tree | 52ad47aa09a66506f9f99d5aefbfdef969cf9086 /README.md | |
parent | 2b2b16037a7a2083a6929c20fbf8ac25763f8ec7 (diff) | |
parent | f3924e8748efe3b035a43ec62eb1ab54179c6221 (diff) | |
download | frege-gradle-plugin-5df7fd223a84c2c4db55668da2b5c0f460a19774.tar.gz frege-gradle-plugin-5df7fd223a84c2c4db55668da2b5c0f460a19774.tar.bz2 frege-gradle-plugin-5df7fd223a84c2c4db55668da2b5c0f460a19774.zip |
Merge pull request #1 from tricktron/f-runTask
RunFrege Task
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 24 |
1 files changed, 20 insertions, 4 deletions
@@ -1,6 +1,8 @@ # Frege Gradle Plugin -Compile frege code with gradle. +![build](https://github.com/tricktron/frege-gradle-plugin/actions/workflows/build.yml/badge.svg) + +Simplifies setting up your Frege project. ## Installation @@ -10,18 +12,32 @@ git clone https://github.com/tricktron/frege-gradle-plugin.git ``` ## How to Use -1. Specify the frege compiler release and version in your `build.gradle`: +1. Specify the frege compiler release, version and main module in your `build.gradle`: ```groovy frege { version = '3.25.84' release = '3.25alpha' + mainModule = 'my.mod.Name' } ``` -See the [frege releases](https://github.com/Frege/frege/releases) for all available versions. +See the [Frege Releases](https://github.com/Frege/frege/releases) for all available versions. + +Optional configuration parameters inside `build.gradle`: +- compilerDownloadDir: defaults to `<projectRoot>/lib` +- mainSourceDir: defaults to `<projectRoot>/src/main/frege` +- outputDir: defaults to `<projectRoot>/build/classes/main/frege` + + + + +### Added Tasks + +- **setupFrege**: Downloads the specified version of the Frege compiler. +- **compileFrege**: All your `*.fr` files in `mainSourceDir` get compiled to `outputDir`. +- **runFrege**: Runs the Frege module specified by `mainModule`. Alternatively you can also pass the main module by command line, e.g: `gradle runFrege --mainModule=my.mod.Name`. -2. Run the newly added `compileFrege` task. All your `*.fr` files get compiled to `build/classes/frege`. ## How to Contribute Try to add another task, e.g. `fregeDoc` to the [FregePluginFunctionalTest.java](src/functionalTest/java/ch/fhnw/thga/gradleplugins/FregePluginFunctionalTest.java) file and try to make the test pass.
\ No newline at end of file |