- Notifications
You must be signed in to change notification settings - Fork7
Frege/sbt-frege
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
- Compile Frege code from your project'ssrc/main/frege/ directory
- Call Frege code from your project's Java/Scala/etc. code
- Launch theFrege REPL with your project's classes and libraries
- sbt 1.0.1+
- Scala 2.4.0+
For sbt 0.13.6+ projects, use sbt-frege version 1.1.3
$ sbt new earldouglas/sbt-frege.g8A project built with sbt-fregename [My Frege Project]: hello fregeTemplate applied in ./hello-frege$ cd hello-frege/$ sbt> testexample.HelloWorldSuite: + multiply 0.008s + showWork 0.016s[info] Passed: Total 2, Failed 0, Errors 0, Passed 2> run[info] 6 * 7 = 42
Add the Frege sbt plugin to your project:
project/plugins.sbt:
addSbtPlugin("com.earldouglas"%"sbt-frege"%"3.0.3")
Write some Frege code:
src/main/frege/example/HelloWorld.fr:
package example.HelloWorldwheremain:: [String]->IO()main _= println"Hello, world!"
Build and run it:
$ sbt> compile> runHello, world!
Try it from the Frege REPL:
$ sbt> fregeReplfrege> import example.HelloWorld (main)frege> main []Hello, world!()
fregeOptions: Seq[String]
- Extra options for fregecfregeSource: File
- Frege source directory (defaultsrc/main/frege/)fregeTarget: File
- Frege target directory (defaulttarget/frege/)fregeCompiler: String
- Full name of the Frege compiler (defaultfrege.compiler.Main)fregeLibrary: ModuleID
- Frege library (fregec.jar) to use (defaultFrege 3.23.288)
fregeReplVersion: String
- The version offrege-repl to use(default 1.3)fregeReplMainClass: String
- The Frege REPL main class (defaultfrege.repl.FregeRepl
)
Though sbt-frege uses 3.24.100.1 by default, Frege REPL 1.3 depends onFrege 3.23.288, so it takes priority when launchingfregeRepl
.
About
Frege support for sbt
Topics
Resources
License
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
No packages published
Uh oh!
There was an error while loading.Please reload this page.
Contributors7
Uh oh!
There was an error while loading.Please reload this page.