executor: Shell helpers

[ distribution, library, mit ] [ Propose Tags ]

Haskell module to execute single or multiple shell commands

[Skip to Readme]
Versions [faq] 0.0.1, 0.0.2, 0.0.3, 0.0.4
Change log ChangeLog.md
Dependencies async (==2.1.*), base (==4.9.*), process (==1.4.*) [details]
License MIT
Author Gianluca Guarini
Maintainer gianluca.guarini@gmail.com
Category Distribution
Home page https://github.com/GianlucaGuarini/executor
Source repo head: git clone https://github.com/GianlucaGuarini/executor
Uploaded by gianlucaguarini at 2017-08-27T18:10:19Z
Distributions NixOS:0.0.4
Downloads 2314 total (87 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Hackage Matrix CI
Docs available [build log]
Last success reported on 2017-08-27 [all 1 reports]




Maintainer's Corner

For package maintainers and hackage trustees

Readme for executor-0.0.4

[back to package description]


Haskell module to execute single or multiple shell commands

Build Status MIT License



Execute a single shell command returning its output

import Executor (exec)

main = do
  -- execute a simple `ls` in the current folder
  res <- exec "echo hi"
  -- hi\n


Execute a list of shell commands in sequence synchronously returning their results in a list

import Executor (execSequenceSync)

main = do
  -- execute synchronously the following commands
  res <- execSequenceSync [
      "echo hi",
      "sleep 1",
      "echo goodbye"
  -- ["hi\n", "", "goodbye\n"]