Packages

p

ammonite

package ammonite

Ordering
  1. Alphabetic
Visibility
  1. Public
  2. All

Type Members

  1. case class Main (predef: String = "", defaultPredef: Boolean = true, storageBackend: Storage = ..., wd: Path = ammonite.ops.pwd, welcomeBanner: Option[String] = Some(Defaults.welcomeBanner), inputStream: InputStream = System.in, outputStream: OutputStream = System.out, infoStream: OutputStream = System.err, errorStream: OutputStream = System.err, verboseOutput: Boolean = true, remoteLogging: Boolean = true) extends Product with Serializable

    Contains the various entry points to the Ammonite REPL.

    Contains the various entry points to the Ammonite REPL.

    Configuration of the basic REPL is done by passing in arguments when constructing the Main instance, and the various entrypoints such as run runScript and so on are methods on that instance.

    It is more or less equivalent to the ammonite.repl.Repl object itself, and has a similar set of parameters, but does not have any of the ammonite.repl.Repl's implementation-related code and provides a more convenient set of entry-points that a user can call.

    Note that the instantiateRepl function generates a new Repl every time it is called!

    predef

    Any additional code you want to run before the REPL session starts. Can contain multiple blocks separated by @s

    defaultPredef

    Do you want to include the "standard" predef imports provided by Ammonite? These include tools like time, grep, the | or |? pipes from ammonite-ops, and other helpers. Can be disabled to give a clean namespace for you to fill using your own predef.

    storageBackend

    Where will all of Ammonite's persistent data get stored? Things like any predef.sc file, compilation/ivy caches, etc.. Defaults include Storage.Folder and Storage.InMemory, though you can create your own.

    wd

    The working directory of the REPL; when it load scripts, where the scripts will be considered relative to when assigning them packages

    inputStream

    Where input to the Repl is coming from, typically System.in, but it could come from somewhere else e.g. across the network in the case of the SshdRepl

    outputStream

    Primary output of code run using Ammonite

    infoStream

    Miscellaneous logging output when running Ammonite. This is typically stuff you want to see when running interactively, but not something you want to see when e.g. you forward a script's output to a file. This by default it goes to System.err

    errorStream

    Error output when things go bad, typically System.err

Value Members

  1. object Constants
  2. object Main extends Serializable

Ungrouped