A Hello Frege (World) example Maven project
This is a demo project showing how to simply develop in Frege, while using Maven as your build tool. It uses the onejar-maven-plugin
to produce an executable uber-jar.
module HelloFrege where
greeting :: String
greeting = "Hello Frege"
main :: IO ()
main = println greeting
Create your source files in src/main/frege/
.
Compile to create the Java source files from your Frege sources and them compile them into .class
files. These java files are created in target/generated-sources
.
./mvnw compile
Compile and run using maven:
./mvnw compile exec:exec
Create the executable uber-jar with:
./mvnw package
The resulting jar file is created in target/${project.name}-${project.version}.run.${project.packaging
. e.g. target/hello-frege-1.0-SNAPSHOT.run.jar
Execute the jar:
java -jar target/hello-frege-1.0-SNAPSHOT.run.jar
Hello Frege
- Run QuickCheck tests