News for hackers. Stuff that matters.
Re:Fish sucks (but your shell sucks more) by jimbokun on Wednesday December 22, 2010 @12:40PM (#2031862)
For me, one issue with programming language shells is just getting ls, cd, etc. working with tab completion.

The other big issue is having to build up commands to execute through String concatenation, which feels just as awkward and inelegant as building up SQL commands through String concatenation. Maybe you could do some funky namespace stuff where programs on your path are imported as functions?

    grep("foo", "bar.txt")
(Note we still have the superfluous quotation marks. How to get rid of those?)

In short, a shell is a DSL for executing programs, redirecting IO, and exploring a file system. It is hard to tweak a general purpose programming language to the point where it is better at those tasks than a shell.

I imagine some of the programming language specific shells mentioned in the article have found ways of solving these problems, and I would be interested in hearing what those solutions are.

Re:Fish sucks (but your shell sucks more) by technomancy on Wednesday December 22, 2010 @03:14PM (#2032298)
> I imagine some of the programming language specific shells mentioned in the article have found ways of solving these problems, and I would be interested in hearing what those solutions are.

Eshell does a great job at this; it feels like a shell, but it also feels like invoking lisp functions. Obviously you're not typing direct function invocations otherwise you would have to quote all your strings, etc; but it's pretty close. You can pipe output from processes straight into Emacs buffers or even into functions. All the shell commands that have nicer Emacs equivalents (grep, top, man, etc) get intercepted so you get the enhanced hyperlinks in grep results, etc. I find it absolutely indispensible.

http://www.masteringemacs.org/articles/2010/12/13/complete-g...

Re:Fish sucks (but your shell sucks more) by jimbokun on Wednesday December 22, 2010 @06:25PM (#2032867)
Um, wow! Eshell could be just what I've been looking for, considering I spend much of my day in Emacs anyways. Might be time to brush up on Emacs Lisp...
Re:Fish sucks (but your shell sucks more) by albertzeyer on Wednesday December 22, 2010 @04:43PM (#2032565)
What does DSL stand for?

Edit: Ah, I guess it is Domain-specific language.