Live data from Hacker News

Zshell

zsh.org

21–30 of 37 posts

Re: Zshell

#21
post #9

Somewhat related is "Oh My ZSH!" which is basically zsh on steroids, it's always one of the first things I install on a new computer. It gives things like new colors, themes, plugins, and more. Highly recommend you check it out. https://ohmyz.sh/

This + ohmytmux is my go to

Re: Zshell

#24

Earlier quoted context omitted.

zsh has better completion, command line editing capabilities, and language features. It's not even close. I can port my bash configuration to zsh in mere minutes, but it's impossible to port my zsh configuration to bash. The reason is simple. Bash just lacks so many features. > For example, it is common to see command line tool come with bash completion files, less so with zsh. It's rare for bash to complete anything…

> It's rare for bash to complete anything but filenames. zsh gives me subcommands and flags with descriptions. I think that hasn't been true for a very long time, although it might be that I'm biased because I've been installing the "bash completion" package alongside bash on all my systems. (In my case "apt-get install bash-completion".) bash typically completes commands, sub-commands, flags, and file/directory name…

I have tried bash-completion and it doesn't make much of a difference. It's already underwhelming that bash requires third party completion frameworks to get completion working beyond command names, variable names, and filenames. But even with bash-completion, completion for the most common commands are either missing or incomplete.

Take grep, for example. I only get --binary-files, --context, and --null. That's only three out of a few dozen options. Or tar, which only shows c, t, and x. For ls, probably the most frequently used command, only --color and --help. Git requires another third party completion framework. Unfortunately, those are the best case examples. For other commands like vim or emacs, option completion is missing. The same even goes for bash builtins. And don't get me started on completion behavior. Though I will say the lack of descriptions for each option takes away half the usefulness of shell completion.

zsh can actually use completion functions written for bash. But I never felt the need.

Re: Zshell

#25
With bash and all of it's improvements over its' predecessors and rivals (csh), I'm not sure what need there is to throw resources at new shells such as zsh and fish etc?

[pulling my tongue out of my cheek, I honestly never have found a reason to use anything other than bash -but that's just me]

Re: Zshell

#26
post #3

Earlier quoted context omitted.

I tried to give zsh a shot as a bash replacement but ultimately returned to bash. My main pain point was that zsh was really difficult to configure out of the box and a lot of the completions were much slower (cpu/wall time) than the equivalent completion in bash. I'm sure some of that was simply ignorance on my part.

I have had someone sing the praises of zsh, tried it, was like "that isn't so much better than bash" and went back. Then I heard about oh-my-zsh, tried zsh with oh-my-zsh, and stayed. I still think it's not a big deal, but it is an improvement.

I'm pretty much in the same boat. Heck, once I learned that BSD's /bin/sh gives you history (and I think filename completion?) I switched to that when I'm on BSD (I don't feel strongly enough about it on Lnux, which often uses dash and is more of a headache).

Then again, I don't do much with the shell per se (not writing scripts or any thing like that).

Re: Zshell

#27
post #25

With bash and all of it's improvements over its' predecessors and rivals (csh), I'm not sure what need there is to throw resources at new shells such as zsh and fish etc? [pulling my tongue out of my cheek, I honestly never have found a reason to use anything other than bash -but that's just me]

In fairness, zsh is only newer than bash by a year. Both are about 34 years old.

Re: Zshell

#28
post #11

Earlier quoted context omitted.

I’ve been using zsh for a while now and you just blew my mind!

Emacs' standard find-file function also does it, and I've since gotten so used to it that it's very irritating when I have to use a piece of software that doesn't complete like that.

There have been decades of work on file name completion put into Emacs, nothing I’ve seen comes close. Currently I’m using add on packages vertigo, orderless, marginalia, consult, embark, and corfu to handle completion. These packages all work together to produce a crazy good setup, but in the past I’ve used helm, ivy, icicle, and vanilla Emacs. Every one of these open source completion frameworks works great.

Of course, I’ll never get back the time spent fiddling with my 1600 line Emacs configuration file.

Re: Zshell

#30
post #28
post #11

Earlier quoted context omitted.

Emacs' standard find-file function also does it, and I've since gotten so used to it that it's very irritating when I have to use a piece of software that doesn't complete like that.

There have been decades of work on file name completion put into Emacs, nothing I’ve seen comes close. Currently I’m using add on packages vertigo, orderless, marginalia, consult, embark, and corfu to handle completion. These packages all work together to produce a crazy good setup, but in the past I’ve used helm, ivy, icicle, and vanilla Emacs. Every one of these open source completion frameworks works great. Of cou…

Oh man, I've tried using Ivy, but it's terrible. I tried typing '~/.c/r/r' to quickly get to my RetroArch config file, and I immediately got stuck in '~/.cache'. With Vertico it Just Works (R). Icomplete (whose vertical mode is part of Emacs now) can also do it, but I prefer Vertico's UX as the way Return and 'C-j' work in Icomplete is opposite to what I naturally expect and rebinding them doesn't work that well.
Post reply on HN