1. 9
  1. 2

    I like the idea of a “shell language”. I know that OSH is working towards that, with bash compatability. Bash is okay, but anything larger than a few hundred lines of shellscript becomes unweildly. Recently I’ve started using fish, and I like what they’ve done with scripting and cleaning their syntax up.

    I’ve had a thought in the back of my head to make a shell language that does away with kruft of and is slightly more type-safe than typical shell languages, but then I’ve just gone and re-invented Perl. But Perl feels too cumbersome as a shell language… I’m rambling at this point, but the idea of a shell language that isn’t strictly a REPL for day-to-day interaction has been an interesting thought to me. Something between Perl and Fish would be ideal.

    1. 2

      “a shell language is for scripting a smallish number of commands, doing a bit of error checking, and perhaps looping or interacting with the user slightly This sort of job is a bit too cumbersome in Python, Perl, or JavaScript.”

      Is this even possible in JS!?

      1. 2

        There’s nothing you can’t do in JS, as to whether you should is another question entirely.

      2. 1

        I use F# for my pocket calculator, workhorse, and scripting language. Occasionally I write scripts in javascript though. I think F# would work as a shell language, but it lacks the hooks to properly do it right now without using Fake, and it seems weird using a build tool for shell scripts… The type inference means I can write typesafe code quite quickly.

        I don’t write in any systems languages, but if I did I guess I’d probably write C.