forked from Lainports/freebsd-ports
A modern replacement for the Bash system shell. Provides a systems shell in the high-level Scala language, letting you seamlessly mix system operations with real code without the hassle or the frustration of trying to write complex code in Bash. Ammonite lets you use the Scala language for scripting purposes: in a Read-Evaluate-Print-Loop (REPL), as scripts, as a library to use in existing projects, or as a standalone systems shell. WWW: https://ammonite.io/ PR: 235759 Submitted by: Jens Grassel <jan0sch@mykolab.com>
19 lines
601 B
Text
19 lines
601 B
Text
To use ammonite as a shell you must(!) setup a configuration file
|
|
~/.ammonite/predef.sc with a least the following minimal content:
|
|
|
|
interp.load.ivy(
|
|
"com.lihaoyi" %% "ammonite-ops" % ammonite.Constants.version
|
|
)
|
|
interp.load.ivy(
|
|
"com.lihaoyi" %
|
|
s"ammonite-shell_${scala.util.Properties.versionNumberString}" %
|
|
ammonite.Constants.version
|
|
)
|
|
// This @ is necessary for Ammonite to process the `interp.load.ivy`
|
|
// before continuing.
|
|
@
|
|
val shellSession = ammonite.shell.ShellSession()
|
|
import shellSession._
|
|
import ammonite.ops._
|
|
import ammonite.shell._
|
|
ammonite.shell.Configure(interp, repl, wd)
|