top | item 26063335

(no title)

max_streese | 5 years ago

I wonder what people think about Ammonite (https://ammonite.io/)?

It's not Lisp but Scala so may not be the authors language of choice however it can be used as a Shell: https://ammonite.io/#Ammonite-Shell

I am personally using it and compared to a classical shell like Bash it's really nice for more structured data related tasks (exploring some API, checking some data, creating a bunch of PRs at once, ...).

It also makes use of Scala's adjustable syntax and functional concepts so you basically get shell piping but in a strongly typed fashion (e.g. `ls.! |? (_.ext == "txt") | (os.read)` would produce a list of strings representing the contents of all files ending in .txt of the current directory).

Also I am curious what people think of PowerShell which as of PowerShell Core is usable on all platforms as well.

discuss

order

majkinetor|5 years ago

Looks almost exactly like PowerShell in syntax but I suppose its even more powerful given lisp heritage.

Its hard to beat PowerShell tho given its integrated in infinite number of tools on Windows platform and growing number on Linux.

pjmlp|5 years ago

PowerShell is the only mainstream shell that builds on the ideas of Lisp Machines, Xerox PARC and ETHZ workstations, naturally I am quite found of it, despite some of its quirkiness.

It does structured data, native support for extending it via .NET and native libraries and at least on Windows, can plug into OS Automation libraries.

What it misses is graphical display on the REPL.

I can easily see PowerShell Core replacing my uses of Python in what concerns Linux VMs.

swiley|5 years ago

I think this talk actually came up in a thread on the guile mailing list about adding powershell as a guile language.

Ambrevar|5 years ago

I've never tested Ammonite, only read the https://ammonite.io/#Ammonite-Shell, so I'm only guessing here.

From what I understand, Ammonite was designed as a "readline shell" as I wrote in the article. It perpetuates this approach that everything is a command.

The thesis of my article suggests we do the opposite: I'm suggesting to rethink shells by starting from the interface (here the SLY REPL) and then implement the shell features.

In particular, it seems that Ammonite does not support back-references and I'm not sure it has an interactive inspector.

While Ammonite seems to be a definite improvement over the _syntax_ of Bash, etc., I'm not sure it brings much novelty in terms of user interface. But again, I know very little about it so I may have missed some features :)