Live data from Hacker News

Ask HN: Are alternative (oil, nu, etc.) shells usable as daily drivers?

news.ycombinator.com

41–50 of 146 posts

Re: Ask HN: Are alternative (oil, nu, etc.) shells usable as daily drivers?

#42
post #27

Earlier quoted context omitted.

> Enlighten me if this I missed the point of Powershell. Plain-text has gotten annoying to me now (having to shell out to grep, cut, and awk is very meh). What's your pain point when trying to use powershell?

What I feel Powershell does not give: short and simple command names, little syntax, and return values that are interpretable at a glance. And there's muscle memory of course, that's on me!

Every command has a short name.

A handy "punctuations" cheatsheet I found on reddit: https://www.red-gate.com/simple-talk/wp-content/uploads/2015...

Short aliases for all major commands: https://devblogs.microsoft.com/scripting/table-of-basic-powe...

Some commands have more than one alias, and you can set your own, of course.

PowerShell also has a very nice help system. For any commands that Microsoft provides, you can type : Get-Help Get-ChildItem

It will list all the various parameters, as well as the various aliases.

As far as return values, you can do $? or type out $LastExitCode - it works the same way you expect.

For a fuller help view you can type "help Get-ChildItem" (all commands and parameters are NOT case-sensitive - it does not care if you type LS or ls, get-childitem vs GET-CHILDITEM does not matter). I prefer this - it helps in remembering.

Re: Ask HN: Are alternative (oil, nu, etc.) shells usable as daily drivers?

#43
I think they're all fine (if they claim some sort of stability) with the proviso that you're going to occasionally want to drop into bash or something to check something out before committing it to a script.

(I assume you're talking about interactive use, not using them as the shebang line in your scripts. I wouldn't do that. But mainly just because then you need everyone to agree to install it, or to install it on your servers, etc.)

> Fish is probably usable, but outside of fish

I use fish, have for years, and I say the above to include it. Sometimes I'm not certain something works as I think it does (bash's myriad interpolation/variable manipulation techniques say) and so I switch shell to test it.

It does have bugs and weirdness of course, especially the vi mode, but it's not going to .. idk, rm -rf / when I only told it to rm -rf ~/.cache/* or something.

Re: Ask HN: Are alternative (oil, nu, etc.) shells usable as daily drivers?

#44

I am a fish fan… but even fish has some difficulties, as many scripts and tools in the wild expect a bash-compatible shell. Otherwise, it is excellent and I use it on my computers 100% of time. I guess other alternative shells like nu have about the same level of usability. If you like them, you can use them.

Probably best to use it as your interactive shell and still have bash or some other POSIX shell for scripts, unless they're intended for your personal use.

Re: Ask HN: Are alternative (oil, nu, etc.) shells usable as daily drivers?

#45

Earlier quoted context omitted.

I use fish too. My favourite feature is typing part of a command and using up and down arrows to cycle through the results, as opposed to ctrl+R and...I don't remember which one. Functions are easy to define too.

You can easily get bash to do that by adding these lines to your .inputrc file. "\e[A": history-search-backward "\e[B": history-search-forward "\e[C": forward-char "\e[D": backward-char

Most things in fish can be achieved with customization and configuration in other shells, like zsh or bash.

The point of fish is a sane set of defaults that doesn't require customization and is good enough.

Re: Ask HN: Are alternative (oil, nu, etc.) shells usable as daily drivers?

#46
post #11
post #4

Bit of a strange one maybe but for my windows machine I've actually been using cmder (conEmu) with ZSH and over the past few years have been extending it with plugins to suit just right. It's super fast supports everything I need now and couldn't work without it.

Correct me if I'm wrong, but cmder is a terminal emulator not a shell. Beside this cmder is really great, but recently I switched to MS's own Terminal, which is maybe even better in my opinion. Especially the integrations with wsl2.

Right the shell is zsh integrated into it. I keep associating them together! Should have clarified!

I haven't played with ms' really but interesting the wsl2 integration.. will check it out.

Re: Ask HN: Are alternative (oil, nu, etc.) shells usable as daily drivers?

#47

I use `fish` as my main shell. It's closer to POSIX than eshell or oil, but it's definitely not POSIX. Personally, the main thing I like about it is that I can't copy paste bash commands. It forces me to read and understand and then convert. It also has some quality of life stuff I really like. I think next time I'm just going to go back to ZSH though as I feel I have learnt enough from the experience of using it tha…

Another fish user reporting in.

I don't care too much about bash compatibility. I don't even care shell scripting in my shell - when I need to write a script I write a sh script (or python for more complex ones). I just want a shell that's easy to use and user friendly.

For some reason none of the other alternative shells "click" for me - I love the idea of having objects in my shell (like in nushell, or powershell), but all the implementations I've tried are just clumsy to use and get in the way. Whereas fish is awesome and works out of the box - barely need for any configuration/

Re: Ask HN: Are alternative (oil, nu, etc.) shells usable as daily drivers?

#48

I am still kinda bitter about mac os replacing the default bash with zsh. I gained nothing from that unwanted update, but got compatibility pains suddenly. Is something is more complicated than a one-liner, use a real programming language instead, with proper building blocks, tooling and documentation. Use something like Go to crosscompile if you don't want to depend on something on the host machine. In my experience…

I've watched a one line bash pipeline turn into a thousand line python program over the course of about a week. It didn't need new functionality, it was just not proper engineering to leave it in bash. We never did agree on whether that was right or not. It was something involving digging information out of elf binaries where the python libs were much more verbose than the flags passed to readelf (maybe objdump, it w…

subprocess.check_call() is more verbose than bash, but probably a better option.

Re: Ask HN: Are alternative (oil, nu, etc.) shells usable as daily drivers?

#50

Earlier quoted context omitted.

I use fish too. My favourite feature is typing part of a command and using up and down arrows to cycle through the results, as opposed to ctrl+R and...I don't remember which one. Functions are easy to define too.

You can easily get bash to do that by adding these lines to your .inputrc file. "\e[A": history-search-backward "\e[B": history-search-forward "\e[C": forward-char "\e[D": backward-char

Fish shell search and suggestions are awesome, and not comparable to what readline gives you. I don't know how it does that, but the shell understands the concept of files, commands in PATH, and CWD. So depending on the directory you are in, after typing "vim " you will get different suggestions (completable by right arrow). Somehow it knows what I mean 80% of the time.
Post reply on HN