Live data from Hacker News

Fish shell

fishshell.com

71–80 of 120 posts

Re: Fish shell

#71
post #64

Earlier quoted context omitted.

I really don’t get this argument. In my shell I don’t type scripts on the prompt. I use fish most of the time as a shell, but I still write bash or even sh scripts, because fish is not installed on most systems. If you run a bash script from fish, it is still executed by bash (because of the shebang).

But one of the selling points of fish is (from their website, I am not a user) that it has sane scripting. That point appealed me most. If I continue have to use bash for scripting, I wonder what fish provides over zsh.

For me, the main thing fish provides over zsh is nice defaults. oh-my-zsh can be incredibly slow, and without it zsh does take a reasonable amount of scripting & setup to make it as "nice" to use (which is why oh-my-zsh exists).

I think their "sane" scripting is more about ux for writing short disposable logic (the type you write in a terminal), rather than more detailed/advanced/structured programming that you might save to a shell script file.

Bash/zsh walk the line of being usable enoughh for typing terse quick commands (terminal syntax) while also being complex enough for writing large scripts (programming language). They end up being imperfect at both.

Re: Fish shell

#72

Nit: Fish Shell is a bit redundant, as Fish stands for "Friendly Interactive Shell". Now that's out of my system, fish is fantastic and made me realise importance of sensible defaults. I tried zsh but configuration took longer than I would have liked, and oh-my-zsh is too bloated to start instantly. Compared to that, I have practically 0 modifications in my Fish config, apart from few aliases. I don't use fish for mo…

I disagree that it's actually redundant. It's like if back in 2004 somebody said "Apple computers are overpriced and underpowered." Technically, "Apple" in that sentence stands for "Apple Computer," so you're saying "Apple Computer computers are overpriced and underpowered." But that's fine, because it's just part of the company's name, not actually a redundancy. No copy editor would have flagged that, but they would have flagged attempts to remove the redundancy by saying things like "Apples" or "Apple Computers." Similarly, Fish is a name, so adding "shell" is useful in identifying the thing you're naming.

Re: Fish shell

#73

Earlier quoted context omitted.

It is. See the difference: GNU Operating System -> GNU's Not Unix Operating System Fish Shell -> Friendly Interactive Shell Shell One expands to include the original acronym, but doesn't duplicate the descriptive extra words. The other doesn't expand to include the original acronym, but does duplicate the descriptive extra word. In other words, one is recursive but not redundant, the other is redundant but not recurs…

What about bash shell? Bourne Again SHell shell. That's the same thing. But i think it can be a helpful distinction between using bash shell as an interactive shell and using the bash scripting language.

Yup. I'm one of those folks who thinks that RAS syndrome is an entertaining and occasionally useful language quirk, and not at all a problem.

For example, even within a computing context, saying "Fish shell" just might help someone understand that you're talking about the Unix shell and not the cipher, and would always help someone who's not familiar with Fish to at least understand that you're talking about an alternative Unix shell.

By contrast, whenever someone posts a Hacker News article about ML, the first comment is invariably someone complaining that they thought it would be about machine learning, and this is unnecessarily confusing, and a borderline injustice, it should change its name, etc. It would probably be easier for everyone involved if it were idiomatic to say "ML language", even thought doing so would be redundant.

Re: Fish shell

#74
post #16

So the massive drawback of fish is it's incompatible with bash (and other shells people use). If you're in fish, this is easily remedied because almost every machine has bash too. However, you can't expect another machine to have fish. However, I just really like fish. I also live out of my own shell, and I don't spend much of my life remote-ing into other machines. When I do, my mind flips into bash just as easily a…

> So the massive drawback of fish is it's incompatible with bash (and other shells people use).

This drawback is also its advantage, as it doesn't need to repeat all the Bourne-ish problems. (You seem to like this :-), just pointing it out for the others.)

I think people who are interested in how they use the command line will not have a problem to learn two shells, fish for the personal use and something Bourne-ish for scripts that might run on other machines, or by other users.

Re: Fish shell

#75
post #16

So the massive drawback of fish is it's incompatible with bash (and other shells people use). If you're in fish, this is easily remedied because almost every machine has bash too. However, you can't expect another machine to have fish. However, I just really like fish. I also live out of my own shell, and I don't spend much of my life remote-ing into other machines. When I do, my mind flips into bash just as easily a…

I think this warning is actually harmful: Years ago, I read this argument about fish and it turned me completely off using it. Only more recently have I really realised this never applied to 99% of my (most people's?) use-cases. The logical step many people miss is that shebangs make the compatibility of the user's shell largely irrelevant: the only real compatibility concerns are the bash version or `sh` aliasing on…

> Only more recently have I really realised this never applied to 99% of my (most people's?) use-cases.

every time someone asks "how do i accomplish X task on the command line" (witness literally thousands of Stack Overflow posts like this) the answer is in bash.

so, i say it applies to essentially every use case where you didn't already know how to do it.

I love fish, but the fact that every answer to your questions is written in another language and has to be translated affects EVERYONE.

Re: Fish shell

#77
post #16

So the massive drawback of fish is it's incompatible with bash (and other shells people use). If you're in fish, this is easily remedied because almost every machine has bash too. However, you can't expect another machine to have fish. However, I just really like fish. I also live out of my own shell, and I don't spend much of my life remote-ing into other machines. When I do, my mind flips into bash just as easily a…

I run Fish on all my machines as well, and it's not like it's _that_ different from Bash. Maybe just for me, since I do not use either to write actual scripts. Only thing I notice on the command line is not using a dollar sign before open parens.

Re: Fish shell

#78
post #16

So the massive drawback of fish is it's incompatible with bash (and other shells people use). If you're in fish, this is easily remedied because almost every machine has bash too. However, you can't expect another machine to have fish. However, I just really like fish. I also live out of my own shell, and I don't spend much of my life remote-ing into other machines. When I do, my mind flips into bash just as easily a…

I find fish is a comfortable interactive shell and dash is a performant script-running shell. Bash is in the middle.

Re: Fish shell

#79
post #16

So the massive drawback of fish is it's incompatible with bash (and other shells people use). If you're in fish, this is easily remedied because almost every machine has bash too. However, you can't expect another machine to have fish. However, I just really like fish. I also live out of my own shell, and I don't spend much of my life remote-ing into other machines. When I do, my mind flips into bash just as easily a…

About 98% of common POSIX shell usage is covered by fish, right down to identical syntax. (Not everything is.) Biggest tip for fish switchers: set fish as your terminal's shell instead of changing your login shell.

I just start fish from .bashrc:

https://github.com/pkulak/dotfiles/blob/master/.bashrc

Re: Fish shell

#80

Earlier quoted context omitted.

I think this warning is actually harmful: Years ago, I read this argument about fish and it turned me completely off using it. Only more recently have I really realised this never applied to 99% of my (most people's?) use-cases. The logical step many people miss is that shebangs make the compatibility of the user's shell largely irrelevant: the only real compatibility concerns are the bash version or `sh` aliasing on…

> Only more recently have I really realised this never applied to 99% of my (most people's?) use-cases. every time someone asks "how do i accomplish X task on the command line" (witness literally thousands of Stack Overflow posts like this) the answer is in bash. so, i say it applies to essentially every use case where you didn't already know how to do it. I love fish, but the fact that every answer to your questions…

> every time someone asks "how do i accomplish X task on the command line" (witness literally thousands of Stack Overflow posts like this) the answer is in bash.

I don't get this argument: The solution is to search for:

"how do i accomplish X task in fish"

This is what I do with xonsh.

Of course, the bigger point that is being missed is that when someone opts to use a shell like fish or xonsh, they're less likely to search how to do X! The reason they picked another shell is often because it is easier to use, etc. In the case of xonsh, it's mostly just Python. I do a lot more in it than I could do in bash, because I don't need to search the Internet for anything.

Post reply on HN