How to invoke bash or shell scripts from a haskell program?

前端 未结 4 2346
佛祖请我去吃肉
佛祖请我去吃肉 2020-12-29 22:16

I\'m writing some shell scripts with haskell, which I\'m running in gitbash, but there are a few other existing scripts I\'d like to be able to use from those scripts.

4条回答
  •  被撕碎了的回忆
    2020-12-29 22:52

    Of course. You can start by using system to invoke external processes.

    More sophisticated piping and process control is available in a cross-platform way from the System.Process library.

    Finally, you can consider porting your shell scripts to Haskell, via shell DSLs.

提交回复
热议问题