Package

purescript-simple-child-process

Repository
corajr/purescript-simple-child-process
License
MIT
Uploaded by
corajr
Published on
2017-09-03T20:51:16Z

Simplified wrappers for common Node.ChildProcess operations.

Installation

bower install purescript-simple-child-process

Usage

module Main where

import Prelude
import Control.Monad.Aff (Aff, launchAff)
import Control.Monad.Aff.Console (CONSOLE, log)
import Control.Monad.Eff (Eff)
import Control.Monad.Eff.Exception (EXCEPTION)
import Node.Buffer (BUFFER)

import Node.ChildProcess.Simple (CHILD_PROCESS, execAff')

type ExecEffects e = (buffer :: BUFFER, cp :: CHILD_PROCESS, exception :: EXCEPTION | e)

main :: forall e. Eff (ExecEffects (console :: CONSOLE | e)) Unit
main = void $ launchAff do
  result <- execAff' "echo \"Hi\""
  log result

Documentation

Module documentation is published on Pursuit.