Live data from Hacker News

Xonsh: Python-powered, cross-platform, Unix-gazing shell

xon.sh

91–97 of 97 posts

Re: Xonsh: Python-powered, cross-platform, Unix-gazing shell

#91
post #41

I love the concept, and I am generally happy with how it works. I think it should catch on. Except the damned name. Come on guys , there are already enough crazily named things out there, you didn't have to be another one :(

ehh.. I keep wanting to call it "nosh" or spell it "xnosh" but I'm sure if it catches on people will remember. Plus it's easy to use with a search engine, unlike "Go" or "Rust." I will say I prefer names that can be searched for on their own (e.g. with Go people typically search for "Go lang"). And as much as I love Void Linux, it's better named than all the xbps-* package manager commands.

Nosh means something different in the UK... Check Urban Dictionary and you might rethink it as a shell name :P

Re: Xonsh: Python-powered, cross-platform, Unix-gazing shell

#92
post #89

Earlier quoted context omitted.

I think that anyone who is trying to imagine "the next shell" owes it to themselves to try PowerShell. It's .NET based and very, very different from the sh lineage, but I absolutely love its ability to use objects instead of strings as the underlying transmission medium between "processes". E.g. ls gives you file descriptors, ps gives you process descriptors, etc.

I was just about to ask if it is available for Linux, but then I saw that the official page advertises its cross-platform properties [1] :D I know about the different concept of Powershell for quite a while now, but since it is MS tech I didn't expect it to be available for Linux. Maybe I will try someday how it feels, but I am sceptical as the thing I like most about POSIX shells is that everything is just text and…

The boundary layer between text and object is definitely a weak spot in the abstraction for PowerShell. That's the main reason why I don't consider PowerShell strictly superior.

That said, the way the language is designed makes calling into compiled .NET code seamless, which in turn makes doing really sophisticated shell scripting a breeze. When I saw what xonsh was trying to do, I recognized a lot of "PowerShell solves this problem a bit more gracefully".

Re: Xonsh: Python-powered, cross-platform, Unix-gazing shell

#93

Earlier quoted context omitted.

Wouldn't it make more sense if it was called "Ponsh" then? Heck, now that I think of it, "posh" would be a perfect name for a Python-powered shell.

PowerShell went for "pwsh" instead of "posh" because posh is already a name of a shell - https://www.commandlinux.com/man-page/man1/posh.1.html

Damn. Maybe go for "Posh Again" instead, in the bash tradition :)

Re: Xonsh: Python-powered, cross-platform, Unix-gazing shell

#94
post #75

Earlier quoted context omitted.

Ugh. I have so many conflicting opinions on this question. So, Xonsh is superior in the manipulation of shell objects. I felt super at home changing the shell prompt and configuring/extending the default Xonsh functionality. This is all because it's literally a superset of Python. Fish however, blows Xonsh out of the water when it comes to autocomplete and navigation. Xonsh's autocomplete / suggestions are very very…

>I wrote a small blog post about it here [0] I work on fish, and one of the things that the upcoming fish 3.0 contains is a new `math` builtin (previously we shipped a function of that name that just wrapped `bc`). So your math expressions here are interesting to me, because they work in math (with the caveat that ` ` is still the symbol for globbing, so it needs to be quoted or escaped): $ math 0x113e8b3 18081971 $…

The benefits of xonsh are more than just the quick math, but I'm glad fish is getting something like this. I've had a Python script that does math for me, something like this [0]

I do think something like a Python shell is the best solution (for me), however, simply because of the ease of use with modifying the current state of the shell (environment variables, etc).

[0] https://gist.github.com/wackywendell/919042f19ab6932447df

Re: Xonsh: Python-powered, cross-platform, Unix-gazing shell

#96
post #85

Earlier quoted context omitted.

> building a shell on top of Python seems like a particualar bad choice to me can you say why? Python's stdlib handles a lot of cross-platforminess, Python is mostly easy to write, and is available as or more easily than a C compiler on many platforms.

It's about stability. It is much easier to break a dynamically linked or interpreted script than a statically linked binary. The worst case of fixing a system with a software failure is booting a live-cd and replace the files which cause trouble, but a broken shell and sometimes also a broken package manager are precisely those cases when you have to boot a live-cd.

> It is much easier to break a dynamically linked or interpreted script than a statically linked binary

If we’re talking about new code, why is this the case?

Re: Xonsh: Python-powered, cross-platform, Unix-gazing shell

#97
post #60

I've always been thinking there can be a better shell like having a split pane to show the list of command options with descriptions as you start typing in the command or show snippets of a preset of command options that does task X as in search by use case instead of going to stackoverflow every time. I think the way people handle shell, as in typing commands on a dumb shell, has not improved for decades and I don't…

> a split pane to show the list of command options with descriptions as you start typing

https://github.com/mhayashi1120/Emacs-shelldoc

Post reply on HN