Author here.<p>My main use for this is incremental migration away from bash. I'm not saying this is the best way to do scripts, but it's a pretty great stepping stone. Just following the cargo culting guide [0] can already uplift a bash script without changing the logic too much. From there you can start adding structure.<p>My secondary use case is little scripts in NixOS/nixpkgs. There are some helpers in there that make it quite convenient.<p>[0] <a href="https://github.com/luke-clifton/shh/blob/master/docs/porting.md">https://github.com/luke-clifton/shh/blob/master/docs/porting...</a>
Those of you who use (or used) this as your shell: care to share your experience?<p>It seems a lot less full-featured than <a href="https://xon.sh/" rel="nofollow noreferrer">https://xon.sh/</a>, but maybe you don't need a lot of bells and whistles for regular usage. I mostly run build, execute, and install commands.<p>I'm somewhat enticed at the possibility of being able to wrap common executables into forms that are typed (like nushell or elvish) and manipulate them in a way that leverages the type checker.
shh is a really cool package, and so is turtle and shelly:<p><a href="https://hackage.haskell.org/package/turtle/docs/Turtle-Tutorial.html" rel="nofollow noreferrer">https://hackage.haskell.org/package/turtle/docs/Turtle-Tutor...</a><p><a href="https://hackage.haskell.org/package/shelly" rel="nofollow noreferrer">https://hackage.haskell.org/package/shelly</a><p>shh's "Alternatives" section summarises nicely some of the differences between these:<p><a href="https://github.com/luke-clifton/shh#alternatives">https://github.com/luke-clifton/shh#alternatives</a><p>shh has a neat [fmt| ... |] macro that gets you around escaping strings.<p>shh generally has more Template Haskell support; you may or may not like this.<p>I am personally leaning towards shh because of its "native pipe style".
Related: has anyone tried scheme shell (scsh) and what is your experiences with it?<p><a href="https://en.m.wikipedia.org/wiki/Scsh" rel="nofollow noreferrer">https://en.m.wikipedia.org/wiki/Scsh</a>
This seems fun! Far too few people who are all "your bash scripts shouldn't be 300 lines and have complex logic!" address why people reach for bash scripts in the first place, so kudos for that.
You can’t really move away from bash, unless there would be alternative as widely available on different Unix systems as bash is.<p>Yes, you came up with a nice syntax for your Haskell scripts, but what it cost to install all required dependencies on, for example, newly created Ubuntu server?
Huh, I was just tinkering with the same sort of thing with the same motivations but with F#:<p><a href="https://github.com/williamcotton/fs_playground/blob/main/Scratchpad/PltAwk.fsx">https://github.com/williamcotton/fs_playground/blob/main/Scr...</a><p>Thanks for this, I’m going to borrow a lot of your concepts, especially the added infix operators, those are slick!