Packages

t

scala.sys.process

ProcessImplicits

trait ProcessImplicits extends AnyRef

Provide implicit conversions for the factories offered by scala.sys.process.Process's companion object. These implicits can then be used to decrease the noise in a pipeline of commands, making it look more shell-like. They are available through the package object scala.sys.process.

Source
Process.scala
Linear Supertypes
Type Hierarchy
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ProcessImplicits
  2. AnyRef
  3. Any
Implicitly
  1. by any2stringadd
  2. by StringFormat
  3. by Ensuring
  4. by ArrowAssoc
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Value Members

  1. implicit def builderToProcess(builder: JProcessBuilder): ProcessBuilder

    Implicitly convert a java.lang.ProcessBuilder into a Scala one.

  2. implicit def buildersToProcess[T](builders: collection.Seq[T])(implicit convert: (T) => Source): collection.Seq[Source]

    Return a sequence of scala.sys.process.ProcessBuilder.Source from a sequence of values for which an implicit conversion to Source is available.

  3. implicit def fileToProcess(file: File): FileBuilder

    Implicitly convert a java.io.File into a scala.sys.process.ProcessBuilder.FileBuilder, which can be used as either input or output of a process.

    Implicitly convert a java.io.File into a scala.sys.process.ProcessBuilder.FileBuilder, which can be used as either input or output of a process. For example:

    import scala.sys.process._
    "ls" #> new java.io.File("dirContents.txt") !
  4. implicit def stringSeqToProcess(command: collection.Seq[String]): ProcessBuilder

    Implicitly convert a sequence of String into a scala.sys.process.ProcessBuilder.

    Implicitly convert a sequence of String into a scala.sys.process.ProcessBuilder. The first argument will be taken to be the command to be executed, and the remaining will be its arguments. When using this, arguments may contain spaces.

  5. implicit def stringToProcess(command: String): ProcessBuilder

    Implicitly convert a String into a scala.sys.process.ProcessBuilder.

  6. implicit def urlToProcess(url: URL): URLBuilder

    Implicitly convert a java.net.URL into a scala.sys.process.ProcessBuilder.URLBuilder , which can be used as input to a process.

    Implicitly convert a java.net.URL into a scala.sys.process.ProcessBuilder.URLBuilder , which can be used as input to a process. For example:

    import scala.sys.process._
    Seq("xmllint", "--html", "-") #< new java.net.URL("https://www.scala-lang.org") #> new java.io.File("fixed.html") !