Fish shell 3.0 - faho
https://github.com/fish-shell/fish-shell/releases/tag/3.0.0
======
robin_reala
Apart from the other good stuff in this release, I think this will make a lot
of things much easier:

 _fish now supports && (like and), || (like or), and ! (like not), for better
migration from POSIX-compliant shells_

~~~
hinkley
That’s new? Suddenly I feel less guilty about dodging coworkers who have been
trying for years to get other people to try fish.

But maybe now it’s getting closer to production readiness.

~~~
StavrosK
The fact that it doesn't support your particular preferred syntax doesn't mean
it's not production-ready.

~~~
jhardy54
> your particular preferred syntax

I think it's called POSIX.

~~~
StavrosK
You seem to be making some sort of argument, I just don't know what it is. Are
you saying that fish is not production ready because it's not POSIX-
compatible?

------
ElijahLynn
My favorite feature of fish is `abbr`, e.g. `fish abbr --add g git`. Then you
type `g` followed by space and it just expands it to `g` and you then get all
the autocomplete goodness and don't have to futz with adding autocomplete
support to an alias, because it is the real command. It also helps for
presentations because instead of some obscurely named alias, you can type an
abbreviation and it just expands it out for the viewer to see and learn from.
On top of that, I make abbreviations with long options, that way I can see
exactly what is going on and effectively edit the commands.

~~~
modernerd
You can also type fish_config to launch the fish config web app in your
browser. From there you can add, edit and remove abbreviations from the
“abbreviations” tab directly.

I find this a really user-friendly way of managing abbreviations I've created.

------
buchanae
After 15 years, I still struggle to test if a string is empty in shell
languages. Do I use square brackets, double square brackets, equal sign,
double equal sign, test -n, set -q, wtf mate? Do I need to wrap my string
variable in double quotes? single quotes?

Fish looks great, and I'm going to give it a try, but I ran into these same
old shell scripting issues within 2 minutes of trying to configure my prompt,
which is a bummer. Took me 10 minutes (I'm ashamed to say) to end up at `if
test -n "$git_branch"` (double quotes are critical).

I'll be excited when someone invents a shell that feels natural in this
respect. Perhaps the nature of shells and commands makes this impossible? Or
are we just stuck in a box?

~~~
duckerude
It feels a bit more natural once you've bent your mind enough to understand
what the shell is doing.

The trick is that `test` and even `[` (which is essentially another name for
`test`) are ordinary commands, that exist as stand-alone binaries as well as
identical-behaving built-ins. They masquerade as syntax, but they're really
not. You can even call them from other, non-shell languages:

      >>> from subprocess import run
      >>> run(('/usr/bin/[', '-n', '', ']'))
      CompletedProcess(args=('/usr/bin/[', '-n', '', ']'), returncode=1)
      >>> run(('/usr/bin/test', '3', '=', '3'))
      CompletedProcess(args=('/usr/bin/test', '3', '=', '3'), returncode=0)

That means that they're not allowed to do anything to variables, because the
variables are inside the shell. `test` doesn't see `"$git_branch"`, it only
sees the content of the variable.

Per the normal rules, `"$git_branch"` is an empty string iff $git_branch is
empty or unset. Leaving the quotes off can do unexpected things, though a lot
less so in fish. Using single quotes means you get a literal string, without
any substitution.

You're just looking for an empty string anyway, so you might as well use the
equality operator instead of digging through the 18 (!) unary flags prescribed
by POSIX. So I'd write either `[ "$git_branch" = "" ]` or `test "$git_branch"
= ""`. Some implementations support `==` as another way to write `=`, but `=`
is standard.

This modularity makes the shell simpler, but it's not exactly sane. I think
that providing `[` was a mistake, because it doesn't look like a command, but
maybe having `test` as a command is better than having special expression
syntax just for these cases.

~~~
faho
There are a few misfeatures in `test`, though.

For instance, one way to use it is

       test somestring

to test if "somestring" is empty. POSIX mandates that test with exactly one
argument succeeds iff that argument is a non-empty string, to allow that.
Fish's test is POSIX-conformant.

Now, that means that

        test -n

is true! Which is also triggered for

        test -n $var

if $var has 0 elements.

This is a problem and should be improved.

~~~
CameronNemo
always quote your variables. POSIX won't change this soon, or likely ever.

------
djsumdog
I started using fish around 2013, back when it would occasionally crash and
leave stack traces in the console. I'm really glad I stuck with it though.
Fish has come a long way and it's totally an amazing shell. I really love all
the functionality that's come out of the box and don't really mind learning
new syntax if it means I can get away from old cruft.

------
linsomniac
I made fish my default shell for around a month, and I really liked the smart
suggestions of what command I was going for when I started typing. But the
"vi" mode had enough incompatibilities that it really irritated me, it was
extremely incomplete. Discussions of it with devs went nowhere. Plus, there
were incompatibilities in the language that I could never bring myself to
commit to memory; I might have if the vi mode were better but as it was I
didn't want to get any further invested in it than I was.

In the end I switched back to zsh and enabled "zsh-autosuggestions", which
gave me the thing I loved most about fish, without any of the parts that I
didn't. There's also some other extensions I'd like to try that enhance
history like "McFly" (
[https://github.com/cantino/mcfly](https://github.com/cantino/mcfly) ), based
on this previous zsh-histdb discussion:
[https://news.ycombinator.com/item?id=15041772](https://news.ycombinator.com/item?id=15041772)

~~~
dmix
ZSH seems to have broader community support and there's a plugin for basically
everything. This is why I chose to stick with it over Fish.

If I just wanted a very simple shell, with good defaults, I'd choose Fish. But
much like why I use (Neo)Vim I prefer the DIY approach and have gotten my ZSH
to the point over the years (and a hundred scripts later) where I love it.

But ZSH the language is pretty awful and non-intuitive (although way better
than bash when you dig into it). Even though I've been writing it for years I
still get it mixed up often.

My hope is that Evlish shell will be mature enough soon to use day-to-day,
which is the only one I've seen with a modern scripting language (written in
Go) and is 10x faster than my ZSH (which is very noticeable):
[https://elv.sh](https://elv.sh)

~~~
dancek
Similar story for me, but I consider the POSIX shell language a worthwhile
least-common-denominator language. I avoid using bash or zsh extensions except
interactively (and in a zsh plugin I maintain [0]).

As I think you need to know the standard shell language anyway, new shell DSLs
are a bit of a turn-off to me. If the language is trivial it's not very
powerful and if it's powerful it takes time to learn.

That's why I have high hopes for shells that combine tried-and-true
programming languages and their ecosystems to a thin shell layer. Like
[http://xonsh.org](http://xonsh.org) or [https://docs.racket-
lang.org/rash/index.html](https://docs.racket-lang.org/rash/index.html) .

But if I'm completely honest, I think bash will still be the standard choice
in 5 years and weird shells you haven't heard of will still be weird shells
you haven't heard of.

[0]: [https://gitlab.com/code-stats/code-stats-zsh](https://gitlab.com/code-
stats/code-stats-zsh)

~~~
kbd
Quick correction, the actual url for Xonsh is [http://xon.sh](http://xon.sh).
My understanding is that xonsh.org is an out-of-date unaffiliated mirror that
the author of Xonsh doesn't control :(

~~~
dancek
Oh, oops. Too bad I can't edit anymore. Sad that the out-of-date site os
ranked better on Google for "python shell".

------
jeffbax
I've been happily using fish for maybe two years now, just as a default shell
and not doing anything fancy. Out of the box it is great.

I'm not sure how to feel about only now learning its indexes start at a [1]
though (╯°□°）╯︵ ┻━┻

Love it otherwise.

~~~
nerdponx
Starting at 1 is good for non-programmers, who IMO could benefit the most from
switching to Fish. I would love to see a distro using Fish as the default
shell for non-root users.

~~~
AnthonBerg
When I’ve been teaching people to program, explaining [0] has been a tragic
experience.

Starting at [0] is _not_ objectively better than [1]. I actually believe it is
objectively _worse_.

~~~
StavrosK
I would like to hear your counterarguments to
[https://www.cs.utexas.edu/users/EWD/transcriptions/EWD08xx/E...](https://www.cs.utexas.edu/users/EWD/transcriptions/EWD08xx/EWD831.html),
which seems to me like a compelling argument.

~~~
Renevith
It seems to be mostly about math, with the only mention of array indexing
being that 0 looks nicer. "starting with 0, however, gives the nicer range 0 ≤
i < N. So let us let our ordinals start at zero"

This doesn't seem to be much of an argument so I'm not even sure what to
address.

~~~
StavrosK
How would you do something like Python's `x[0:10] + x[10:len(x)]` in a
1-indexed way? [1:11] + [1:len(x)+1]? That's uglier.

~~~
int_19h
You just make ranges end-inclusive, and then it's x[1:10] + x[11:len(x)].

The best of both worlds is when a language provides both end-exclusive and
end-inclusive slice syntax, as in e.g. Nim: x[0..<10] is end-exclusive, and
it's very clear that it is.

~~~
StavrosK
But then you no longer get back 10-1 elements, you get back 10-1+1.

~~~
thaumasiotes
So what? You're going to have off-by-one errors no matter what convention you
adopt. Python glosses over it by providing the alternative syntax x[-1] for
what you would otherwise have to write as x[len(x)-1]. But it's at least as
valid to provide alternative syntax for inclusive ranges. And logically, if
the first element of x is x[0], the last element _should be_ x[-0], not x[-1].

Half-open intervals are appropriate when you're thinking of them as subspaces
of a continuum. When you're thinking of them as subsequences of discrete
elements, closed intervals are usually more natural.

Ruby is the only language I know that really seems to have tried to address
the problem, providing different syntax for every way you might want to take a
subsequence from an array:

        x[5..8]  # elements [5] through [8], including [8]
        x[5...9] # elements [5] through [9], excluding [9]
        x[5, 4]  # four elements, starting at [5]

If you were working in pure, pencil-and-paper mathematics, you'd choose
whether to index a particular sequence from 0 or 1 based on what made your
formula look nicer. Both are common. But that's not an approach I'd suggest
for a programming language.

~~~
int_19h
One thing I would add - using negative indices to index from end is a bad idea
in general, because you may inadvertently end up with a negative index as a
result of a calculation that you expected to always be positive - and then
instead of an out-of-bounds error, you get silent wrong behavior.

IMO, it's better to have dedicated _syntax_ for index-from-end, as part of the
range syntax. Again, Nim does that: x[0..^1] (although unfortunately they
didn't make it symmetric).

~~~
thaumasiotes
> IMO, it's better to have dedicated syntax for index-from-end, as part of the
> range syntax.

This is true, and note that my suggestion requires it -- the only way to
distinguish x[-0] from x[0] is to have the parser do it; -0 and 0 are the same
_number_.

~~~
int_19h
I mean, you could technically distinguish between positive and negative zero,
if your numbers are all floating points (like JS or Lua). But that would be
even more of a horror show.

------
darkpuma
Still no auto-escaping or quoting for pasted URLs, that's really
disappointing. I respect fish's stated goals of user friedlieness, but I just
don't think they've realized that goal in ways that other more mainstream
shells have:

        > mpv https://www.youtube.com/watch?v=LBoF1e5YDdQ
        fish: No matches for wildcard 'https://www.youtube.com/watch?v=LBoF1e5YDdQ'. See `help expand`.
        mpv https://www.youtube.com/watch?v=LBoF1e5YDdQ
            ^

This, to me, is not user friendly.

For reference, pasting the same URL into zsh with the often touted omz
(incidentally I recommend you use antigen instead) auto-escapes the URL to

        > mpv https://www.youtube.com/watch\?v\=LBoF1e5YDdQ

~~~
faho
What? That's been in for a few releases!

To trigger it, enter a single-quote, then paste the URL, then close the quote
once you're done.

We don't attempt to detect URLs because that can go wrong, and because we
don't know your intention. So we use the fact that you're inside single-quotes
as the signifier that we should escape things - which also allows this to be
used for e.g. pasting shellscript as a literal argument.

~~~
darkpuma
There must be a disconnect here, manually entering a single quote, then
pasting my URL, then adding the closing quote is precisely what I wish to
avoid.

Here is a demonstration about what I'm talking about:
[https://i.imgur.com/d64lwaB.mp4](https://i.imgur.com/d64lwaB.mp4)

> _" We don't attempt to detect URLs because that can go wrong, and because we
> don't know your intention."_

That much I've gathered from seeing this issue raised with fish people in the
past, and in my humble opinion it's the wrong approach. In this mentality fish
is forgetting it's stated goal of being user friendly which should in some
cases, mean making sane educated guesses about the user's intent. How often do
users of the fish shell paste a string that starts with 'http' and contains a
'?' that is _meant_ to be a wildcard? Not very often at all, if ever; fish is
now evidently planning on deprecating that ? wildcard so I think the fish devs
agree!

The way I see it traditional shells aren't user friendly because they take a
conservative approach, doing crap like not enabling fancy autocompletion
features out of the box because _" what if the user is running on a
timesharing PDP-11 and can't spare the CPU cycles?"_ Breaking from that mental
trap is bold and should be commended, but in the case of not escaping pastes I
think fish has fallen into that conservative mindset again. zsh/OMZ does it by
default and I've never heard of anybody getting screwed over because of it.
Fish could and should do it by default too.

~~~
faho
> How often do users of the fish shell paste a string that starts with 'http'
> and contains a '?' that is meant to be a wildcard?

Okay. Now you can do it for http. What about ftp? Or "file://"? Do we detect
_all_ kinds of URLs?

And even if we do, and we don't miss some or see something as a URL that
isn't, what about _other_ kinds of things? What about shellscript? E.g. if I
want to just execute a bash one-liner from the internet, I can do

        `bash -c '`

and paste it and it'll work out. That won't be detected as a URL, because it
isn't one.

And I've seen a case of a URL with variables just yesterday (though I admit
that's a coincidence):

[https://docs.travis-ci.com/user/deployment/custom/](https://docs.travis-
ci.com/user/deployment/custom/) has
"sftp://${SFTP_USER}:${SFTP_PASSWORD}@example.com/directory/filename". How do
I paste that with the zsh thing? Do I need to go back and edit all of that?

So, instead, we have one rule: If you paste it insde single-quotes, it'll be
escaped. If you paste it outside, it'll be inserted as-is (but still not
executed). No matter what the contents, no matter where.

~~~
darkpuma
> _Okay. Now you can do it for http. What about ftp? Or "file://"? Do we
> detect _all_ kinds of URLs?_

Some is better than none, that's the lesson learned from OMZ's implementation
of this feature. It doesn't cover every single scenario, but it covers enough
to make people's lives easier in the common cases. That is the sort of bold
decision making that the fish developers _should_ be doing.

        `bash -c '`
        sftp://${SFTP_USER}:${SFTP_PASSWORD}@example.com/directory/filename

Both of these get pasted unchanged in zsh. I suggest you try it out. But more
to your point, this would get improperly escaped:

        http://${SFTP_USER}:${SFTP_PASSWORD}@example.com/directory/filename

And you know what? That's fine. Because whether you choose to auto-escape or
not, something will break. The question you and the fish developers should be
asking is which is more likely? Auto-escaping works the vast majority of the
time and only fails some of the time. And when it fail in the rare case, the
UX is no worse than when it fails in the common case.

> _" If you paste it insde single-quotes, it'll be escaped."_

First of all, that's not what I see. Maybe you're talking about bracketed
paste mode or something that's invisible to the user, but when I paste a URL
containing wildcards into single quotes in fish, I don't see any escaping
taking place. I assume single quotes are the "verbatim quotes", e.g. `ls
'*.txt'` doesn't show you all txt files because that wildcard isn't expanded
inside those single quotes. With that in mind, it's not clear to me why a
string pasted into single quotes should be escaped, it doesn't need escaping
and I don't see any escaping being done when I try it out myself.

There's nothing magic about making `mpv
'[https://www.youtube.com/watch?v=LBoF1e5YDdQ'`](https://www.youtube.com/watch?v=LBoF1e5YDdQ'`)
work. Dumb old bash accepts that too.

~~~
faho
>Some is better than none, that's the lesson learned from OMZ's implementation
of this feature.

I disagree. I'd rather have predictability here.

>when I paste a URL containing wildcards into single quotes in fish, I don't
see any escaping taking place.

That's because you've not pasted anything that needs escaping. In single-
quotes, only single-quotes and backslashes are special, and they are escaped.

Even if you paste script that itself contains single-quotes, it'll work.

~~~
darkpuma
The truly unpredictable UX is when a noob tries to paste a youtube url into
their shell and gets a bewildering error message about a wildcard (and the
error message carrot doesn't even point at the guilty wildcard!) That is very
far from the behavior the user was predicting, unless they've been around the
shell block a few times already (in which case they could probably make due in
a shittier shell anyway. Is fish optimizing for _' user friendly'_ or _' user
friendly for experiences users'_?)

~~~
faho
>The truly unpredictable UX is when a noob tries to paste

Yes, and you've not solved that.

You've only solved that one special edge-case where they're pasting "a youtube
url".

This only pushes the confusing bit further along, and adds some more cruft on
top!

Quoting is a fact in shells. The way these languages work is through loads of
string interpolation, so you kinda need to learn that. And I'd prefer to make
the rules there simple than add special cases for URLs.

------
mlrtime
To install on ubuntu if you don't want to build:

sudo apt-add-repository ppa:fish-shell/release-3

sudo apt-get update

sudo apt-get install fish

[https://launchpad.net/~fish-
shell/+archive/ubuntu/release-3](https://launchpad.net/~fish-
shell/+archive/ubuntu/release-3)

~~~
ElijahLynn
To install on Arch (w/yay), `yay -S fish`. (just a plug for how easy it is to
install packages on Arch)

~~~
mlrtime
Does yay come default on arch linux?

~~~
ElijahLynn
No, but I'll say that it is the single coolest feature of Arch, and I think it
should be default. I have been able to install every single package with a
`yay` command except for one.

My instructions I have for installing yay are:

Go to
[https://github.com/Jguer/yay/releases](https://github.com/Jguer/yay/releases)
Download the yay release and extract it, a clone won't have the build files,
download the release. cd to the extracted copy ./yay yay (install the AUR copy
of yay using your local copy of yay)

Then `yay -S <package-name>` and done, it grabs the repo if it has to and runs
the build steps to build from source. It is the most frictionless package
management experience I have every experienced on Linux.

And I have used `apt-get` on Ubuntu for many (10?) years (go find the PPA
yourself dammit) and also `yum` RHEL7 for the past year. Fedora and Debian
need something like this too.

------
man-and-laptop
Fish Shell has been having some problems implementing process substitution.
Last I checked, they tried two approaches:

* piping to FIFO files, but it throws an error if you pump too much data into them

* waiting until one process finishes before starting another. That's not a correct implementation either

Bash apparently resorts to black-magic.

~~~
yorwba
The Bash manual seems to imply that they use /dev/fd to implement process
substitution like regular pipes, but passing the pipe file descriptor as its
filename under /dev/fd.

[https://www.gnu.org/software/bash/manual/html_node/Process-S...](https://www.gnu.org/software/bash/manual/html_node/Process-
Substitution.html)

------
hestefisk
Long time zsh user here. Any reason one should try out fish?

~~~
aequitas
Coming from ZSH, Fish is a shell that just worked out of the box for me. It
did everything ZSH did but I didn't have to touch a single configuration file
to make it work. With ZSH I was forced to find all the options I wanted
enabled and tuned or had to resort oh-my-zsh or templates from others to get
all the good stuff. Managing dotfiles across workstations and servers. With
Fish about the only thing I do after installing is set a theme with Git
status.

~~~
arunix
With zsh, I can do ~1, ~2 etc to move around a directory stack. Does fish have
anything like that?

[http://zsh.sourceforge.net/Intro/intro_6.html#SEC6](http://zsh.sourceforge.net/Intro/intro_6.html#SEC6)

~~~
faho
Fish does not include tons of syntactic shortcuts. We try to keep the syntax
fairly free of opaque symbols.

You can use `prevd` and `nextd`, or you can use key bindings, like the default
alt-left and alt-right bindings.

~~~
arunix
How do you go to the nth item of the directory stack? Even bash lets you do
this:

        $ dirs -v
        0  ~/baz
        1  ~
        2  ~/bar
        3  ~/foo
        4  ~/spam

Then "pushd +3" will take you to ~/foo. This hardly seems "opaque".

~~~
faho
That's included, just the `~2` shortcut thing isn't.

~~~
arunix
Which is included? I couldn't find anything like "dirs -v" in the fish manual.
Without that, "pushd +N" isn't very useful.

~~~
nimih
There's a "dirs" command, which lists the directory stack, and a "cdh"
command, which lists your directory history.

------
base698
Fish still doesn't support !! or !command expansion.

[https://github.com/fish-shell/fish-shell/issues/288](https://github.com/fish-
shell/fish-shell/issues/288)

~~~
davewongillies
The bang-bang plugin handles !! and !$

[https://github.com/oh-my-fish/plugin-bang-bang](https://github.com/oh-my-
fish/plugin-bang-bang)

------
entelechy
Cool stuff! Love the modest headline on
[http://fishshell.com/](http://fishshell.com/)

> Finally, a commandline shell for the 90s

It makes me wonder, how would a shell for 2020 look like?

------
duckerude
>? as a glob (wildcard) is deprecated and will be removed in the future
([https://github.com/fish-shell/fish-
shell/issues/4520](https://github.com/fish-shell/fish-shell/issues/4520))

This surprised me, but maybe it's for the best. It got in my way more often
than I used it. I'll still miss it.

~~~
djsumdog
huh ... interesting. I missed that. I often quote URLs when running wget
because of question marks, and I guess I don't have to now.

~~~
aequitas
You still have to watch out for ampersands though.

------
CJefferson
The one thing I miss most in fish is subshells, because I love writing things
like ( (cd $dir && ./run_prog && cd PKG && ./do_stuff) & ), to run a series of
things in the background. Is there any way to do something similar in fish?

~~~
faho
What this does is two things:

\- It keeps the state separate from the main shell, including $PWD (so the
`cd` doesn't affect the main execution "thread")

\- It executes some script in the background

Fish's backgrounding is currently limited to single external commands (not
even functions). That's [https://github.com/fish-shell/fish-
shell/issues/238](https://github.com/fish-shell/fish-shell/issues/238).

It also doesn't have the capability to keep $PWD separate, though other
variables can of course be declared locally. That's [https://github.com/fish-
shell/fish-shell/issues/1439](https://github.com/fish-shell/fish-
shell/issues/1439).

The workaround is, if you actually need this, to run it inside `fish -c`.
Which is essentially what this syntax is doing in the background anyway (it
needs to fork off because `chdir` applies to the entire process).

(Disclosure: I'm a fish developer)

~~~
SomeHacker44
Forking off a subshell is very different, I would think, than forking and
execing a new shell, both from a resource standpoint and an open file
standpoint.

~~~
faho
Not really from a usage perspective though, and resources often don't matter.

If you're doing something like this in the background, then that usually means
it takes a "long" time (or you'd just wait for it). So the overhead of
starting an additional shell simply isn't important.

Not that it's always irrelevant, but that's why the issues are still open.

~~~
SomeHacker44
Agreed, resources often don't matter.

But I do often do something like:

( cd somewhere ; do_something )

just so I can avoid having to do

pushd somewhere ; do_something ; popd

(or the equivalent).

------
jacobherrington
I loved Fish while I used it. I recently stopped using it because I'm writing
a lot of documentation. I prefer to do thing using bash or zsh now so I can be
sure it will work for others.

~~~
jonathankoren
I run tcsh. It won’t.

~~~
naniwaduni
You know you run tcsh. fish users usually know they run fish. You don't expect
to be able to run arbitrary copy-pasted shell snippets in the first place.

~~~
beatgammit
I try to run my scripts on /bin/sh (on a system where that's not just a
symlink to a fancier shell) before posting them. That means it's more
portable, but still not universal. I don't typically have bash on my BSD
systems, and when I do, they're not installed to /bin, so this is also
somewhat out of self interest as well.

------
anderspitman
Something I've been thinking about this week as a vanilla bash user: Does Fish
(or zsh, or others) have the ability to maintain some sort of a global command
history? I often find myself wanting to run the same command in multiple
terminals and currently just copy-paste.

~~~
explainplease
In fish you can use `history --merge` to merge the current shell's history
with other instances of fish.

------
xkgt
How do people manage scripts to be used in such niche shells? I started using
zsh at work recently, while I quite enjoy the shell experience it is a pain to
rewrite all bash scripts to zsh or add lines of codes for compatibility. Any
pointers?

~~~
mixmastamyk
You don’t. ;-) Use fish/zsh interactively, sh for simple scripts, Python for
the more complex.

~~~
xkgt
Yeah I get that. But this method doesn't help for scripts that need to modify
the current session state (such as export session variables). I am guessing
here that such scripts are an edge case and most shell scripts can be simply
executed with sh.

~~~
TheAceOfHearts
Could you give a concrete example of a situation you have in mind? If I'm
understanding you correctly, then one solution could be to create a small
wrapper to exec bash, source your environment-modifying script, and then exec
fish. Are you familiar with exec [0]? fish also has an exec command [1].

I've been using fish for years and it hasn't been an issue. You can keep bash
installed for any hardcore scripting, and just fish as your interactive shell.

[0]
[https://stackoverflow.com/a/38581329](https://stackoverflow.com/a/38581329)

[1]
[https://fishshell.com/docs/current/commands.html#exec](https://fishshell.com/docs/current/commands.html#exec)

------
joshschreuder
Is there anything remotely like this on Windows?

I use Cmder / Conemu now but it doesn't seem to have even 10% of the features
of a fully fledged shell like this.

~~~
faho
cmder and conemu are terminals. They run shells, like bash or zsh, but also
fish.

I've not used it myself, but I know that fish is available in WSL and cygwin
(though this release had some issues there).

~~~
joshschreuder
Yeah I realised after I posted that I was talking about terminals not shells
but it's too late to edit my mistake away :)

Interesting about it working on cygwin / WSL. Maybe I'll give that a go. I'm
sure someone's also made Powershell enhancements that add similar
functionality too.

------
rbosinger
So weird. Last night I ran a bunch of updates and spent some time cleaning up
and configuring my laptop. Preparing for the New Year. I tried to upgrade Fish
and saw that it hadn't had an update since this time last year. I ended up
looking through the release logs and just reading the Fish docs a bit. I never
do this. Now, this morning, this is on Hacker News.

~~~
hnarn
It's not weird, it's a cognitive bias:

Frequency illusion (or Baader–Meinhof effect): The illusion in which a word, a
name, or other thing that has recently come to one's attention suddenly seems
to appear with improbable frequency shortly afterwards.

[https://en.wikipedia.org/wiki/List_of_cognitive_biases](https://en.wikipedia.org/wiki/List_of_cognitive_biases)

~~~
phirschybar
I think it's more like a productive time of year for hackers to get things
done :). The week between xmas and new years is always super productive and
creative for me... it's quiet and there is a subconscious urge to wrap things
up before year end.

------
chrisweekly
Can anyone who's experienced with both fish and zsh comment on reasons fish
might be better?

~~~
okdana
fish doesn't try to support all of the weird historical quirks of Bourne-style
shells, so its grammar and built-in 'API' are far simpler and clearer. Its
out-of-the-box configuration is much much nicer for most people than zsh's.
Completion definitions are easier to read/write. Its source code seems less
byzantine. And its GitHub-based development model is more accessible.

The down side is that it's functionally very limited compared to zsh. fish's
completion functions are easy to maintain, but the trade-off is that they
don't offer the fine-grained contextual control over behaviour that zsh's do.
Features like globbing, sub-shells, job control, co-processes, modules, &c.,
are absent or extremely limited. There are fewer knobs and switches, though as
mentioned it tries to do the right thing for most people by default. And a
consequence of the syntax being clearer is that it's also much more verbose,
which i guess you may or may not appreciate.

Over-all i think fish is a good shell for the (very common) type of person who
doesn't really care about shells but was drawn to zsh just because it has
nicer completion than bash and lets you write fancy prompts. I don't think
it's a good fit, yet, for people who write complex scripts or regularly make
use of stuff like extended globs, background jobs, and fancy parameter
expansions.

~~~
zanchey
Job control should be fully featured - backgrounding, stopping/continuing, and
disowning are all implemented. If there's something missing we'd definitely
look at adding it.

~~~
okdana
Yeah, you're right of course. I think i was conflating job control with sub-
shells, sorry.

------
Barrin92
I like fish's auto completion speed and smoothness but one thing that has held
me back when I checked out fish was that there didn't seem to be a `Ctrl+r`
command that bash and zsh provide to quickly go through history commands.

~~~
robin_reala
You start typing what you want, then hit the up arrow to fuzzy search back
through history.

~~~
AdamGibbins
Is this the only way? Arrow keys require I take my fingers off the home row,
which is far from ideal with the frequency I search shell history.

~~~
waterhouse
Control-P does it too, and is what I normally use. (Generally, I use
control-{n,p,f,b} instead of arrow keys wherever possible. I also have caps
lock mapped to control.)

------
hartator
Does anyone know how it compare to zsh with oh-my-zsh?

~~~
nerdponx
Zsh + OMZ is a slow, unconfigurable mess. If you are new to Zsh, avoid OMZ. If
you are experienced with Zsh, you already know to avoid it.

Fish "just works", and you won't have any lag. It is a delightful beginner
experience, too.

A Zsh veteran could probably replicate parts of the Fish experience in Zsh,
but ultimately they are different tools. I use Fish at home for casual shell
stuff, but I write shell _scripts_ in Zsh, and I use Zsh at work whenever
possible.

~~~
h1d
I guess I try to switch to fish again as like you said zsh with 10 plugins
takes so long to start a shell, like 5 seconds which feels forever when you
want to start typing right then, that I now never quit the shell from remote
machines but just disconnect from its tmux instance so I can go right back
without initializing the shell every time I log in.

~~~
nerdponx
This is also a result of bad plugin design.

Functions should be on fpath, zcompile'd, and loaded with autoload. Otherwise
you have to read and parse 100s of lines of code every shell invocation...
yikes.

------
santix
I was hoping to see that they added a `time` command, which is something that
makes me change to bash every once in a while.

~~~
scbrg
There's an actual program, usually installed in /usr/bin/time. The shell
builtin is not really necessary.

~~~
kurtisc
There's an outstanding issue in the github because the binary doesn't let you
directly time fish functions. You can do

time fish -c '[function]'

but that includes the time to launch fish.

This, of course, wouldn't matter for any reasonable usecase but I like a fancy
prompt and don't like waiting for it to run.

~~~
scbrg
Ah, timing other shell functions is a use case I hadn't considered. Yes, then
you're out of luck I suppose.

~~~
beatgammit
I think $duration is a thing, which is the time it took to run the previous
command. It doesn't separate things like time does, but it's still useful for
some cases.

In fact, I customized my prompt to pretty print the previous command's
duration if it took longer than 3 seconds or something like that.

~~~
avarun
I use the Spacefish prompt plugin[0], which does that as well, and comes with
a whole lot of other goodness!

[0]
[https://github.com/matchai/spacefish](https://github.com/matchai/spacefish)

------
milin
Let me know when it's posix compliant.

~~~
kurtisc
As soon as your bash scripts run with /bin/sh.

You can still have bash installed and anything that requires significant
scripting could probably be done easier with a language for scripting. I want
my shell for my terminal. This is also the reason I don't like the verbosity
of Powershell, however much an OOP paradigm better supports scripting.

~~~
naniwaduni
You can write scripts in the semantics-preserving common subset of POSIX sh
and bash, which is not quite, but close to exactly POSIX sh.

It's a widely-touted meme that scripting is more easily done in a general-
purpose language than in a shell, but this is mostly true of the (common!)
category of tasks which use the shell to launch sed &c. to perform string
processing which is built-in in general-purpose languages. It's comparatively
hard (i.e. verbose and error-prone) to replace a shell language with a
general-purpose language in its core competence, viz. launching processes,
muxing I/O, and coordinating parallel processing.


Pandora Founder Tim Westergren on the iPhone's Importance to Pandora - gordonbowman
http://www.gordonbowman.com/pandora-founder-tim-westergren-on-charlie-ros

======
minalecs
he should be more concerned of his algorithms that continuously replay the
same songs every day.


The art of mastering airline loyalty programs -- Going for Elite - jaf12duke
http://blog.flightcaster.com/part-2-the-art-of-mastering-airline-loyalty-p

======
ben1040
A few years ago I had a job that had me flying 5000 miles a week. I signed up
for AA's status challenge and qualified for platinum status in nearly a month.

I think they charge for taking the challenge now (it was free then) but it's
well worth it. Not only do you get better seats, free bag checking, priority
security access, and earn upgrades, but that was 30,000+ additional bonus
miles I wouldn't have earned had I just skipped the challenge and qualified
for the status the normal way.

Also, if you're on the fringe between status tiers, often times it's very much
worth it to spend a couple hundred bucks on a "mileage run" if it means the
extra EQM will put you into top-tier status.

~~~
Dornkirk
I'm wondering if you know whether there's any program that allows earning
miles to spend on _any_ airline?

I'm going to be doing a trip in two months that will take me from the Mid-West
to SE Asia and then I'll hop a few places in SE Asia before coming back to the
states - I currently don't have any frequent flyer program as I hardly ever
fly (a few times a year) - but I'd hate for this trip to go wasted - plus I
may be traveling quite a bit next year.

~~~
prawn
Last time I undertook a major trip (37 flights through 20ish countries), there
were two main alliances - Star and OneWorld, from memory. If you stuck to
airlines from one of those, your points would be combined.

I don't fly all that regularly (maybe just above average) so things might've
changed since then.

~~~
gaius
Now there is a third - SkyTeam. Plus there is Virgin Atlantic who aren't a
member of any alliance but have one-off deals with individual airlines.

------
mrb
I NEVER understood, and still don't understand, why are people so attracted to
airline loyalty programs? Are the benefits this important? It seems to me the
average frequent flyer can reduce his costs by ~10-20%. This is not much.

~~~
ben1040
If you travel extremely frequently, like every week or every other week, the
benefits save you quite a bit of time and make the general air travel
experience suck a little bit less. For example, the priority security
screening line for passengers with status meant I could sleep an extra half
hour on Monday mornings.

On the other hand if you don't travel that often at all, you probably won't
see much benefit. By reducing capacity and increasing the number of required
miles to claim reward tickets, the airlines keep moving the goalposts.

I'd imagine there are plenty of people out there who choose a given airline
because of the prospect of getting something for nothing through the loyalty
program, but travel so rarely that they'll never accrue enough miles to get
any reward tickets.

------
adambyrtek
Somehow this reminds me of a scene from Up in the Air in which George Clooney
reveals that his dream is to gather ten million miles in order to get
"lifetime executive status, meeting the chief pilot Maynard Finch, and getting
his name painted on the side of a plane."


16 days since last ruby drama - neXter
http://rubydramas.com/
======
bdcravens
I'm a manager of a user group (not Ruby or Rails, but ColdFusion) but when we
have celebs in audience, I always default to them. Members have purchased
their books, and read their blogs; they respect them more than they respect me
or the speaker (usually me, managers commonly speak at smaller communities).
Should they be pricks? No. But that's a question for the universe to deal
with; as for our group, we like the celebs. (Ruby world's Katz's are CF's
Camdens, Nadels, and Fortas - same difference...)

Having listened to Yahuda on various podcasts and whatnot, I get that he
doesn't keep his mouth shut. Sometime's he's a douche, othertime's he's the
smartest dude in the room and should be listened to. If you are a UGM and
didn't expect this, maybe you should decline Yahuda's chance to speak.. his
personality isn't exactly a secret, just saying.

tl;dr pricks will be pricks; experts ditto. Take the good with the bad, and
research celebs.

~~~
JohnBooty
The ColdFusion scene has stars?

There's... there's a ColdFusion _scene?_ Do you guys have dance-offs with the
ASP Classic guys or what?

~~~
bdcravens
Several active conferences. A thriving open source community. ASP classic is a
dead product; All three CF engines released new versions in the last year,
with support for REST, WebSockets, updated ORM support, etc. While you'll
probably never see it used in YC because it's not "cool", there's tons of it
in Fortune 500 and the private sector.

------
danso
From the latest drama, this is a brilliant simile:
[https://github.com/rails/rails/commit/0dd24728a088fcb4ae616b...](https://github.com/rails/rails/commit/0dd24728a088fcb4ae616bb5d62734aca5276b1b#commitcomment-1747128)

> _I can't get behind a change like this. This isn't even syntactic sugar.
> It's more like syntactic aspartame. It might slim down your code, but it's
> also a carcinogen._

~~~
yen223
Hang on, I thought they debunked the whole "aspartame is a carcinogen"
thing...

~~~
EwanToo
They did, yes

[http://www.cancer.gov/cancertopics/factsheet/Risk/artificial...](http://www.cancer.gov/cancertopics/factsheet/Risk/artificial-
sweeteners)

------
overgard
Heh.

As an outsider to the ruby community (though a fan of the language), I'm not
sure I have the right to an opinion on these dramas, but as a frequent
unwitting observer of these events (since these dramas end up on sites I
frequent and so on), I'd like to offer this thought:

The whole "coders-as-rockstars" meme, and the attendant treatment/fascination
with these people -- I would be a slightly happier person if the world let
that idea go. To me, it seems like this idea is where a lot of these dramas
come from. People whose "celebrity" is overvalued, and people who pay way too
much attention to these people. Coders are not rock stars. They're just not.
They might be really good at what they do, they might even be 10x better than
average, but its just not the same thing as being a "rockstar" and all the
preening that comes with that, culturally or otherwise.

I can't think of anything less rockstarish than arguing with people over the
internet or being a jerk at a usergroup.

The fact that these "dramas" are even news to anyone is just a side effect of
the fact that people give certain drama queens way more attention than they
deserve. I mean I'll admit it's entertaining -- but at the end of the day I
feel like the fact that some guy was a jerk at a local conference, I mean, I
just don't care. It's like intellectual junk food. I get a rise out of it, but
it leaves me feeling like I haven't consumed something that makes me a better
person.

~~~
evilduck
You somewhat focus on being a jerk at user groups, but you're perpetuating a
story from a blog post of a third person account that simply speculated about
how someone might have felt without giving almost any context to the situation
or first hand information from the speaker or Yehuda. I've been part of a Java
usergroup where interrupting the speaker/presentation was not only acceptable
but often the norm. Without any context you can't really say how that behavior
was received.

Sometimes I think that Ruby's "drama" is equivalent to Rails' "magic", i.e.
weak criticism perpetuated more by detractors and not really considered a
problem internally.

~~~
zampano
I agree entirely. I started programming with ruby and rails about a year and a
half ago and have made a habit of going to meetups and conferences in the
area. I have seen nothing that wasn't intended to be constructive and helpful
and I would argue that the ruby/rails community is one of the most welcoming
I've run into. I have witnessed some misunderstandings that spun out of
control, but I don't think you can say this is something specific to the ruby
community and I'd argue that it has very little to do with celebrity-seeking.
Any community is going to have some friction between elements at times, and I
think this site just contributes to the overblown perception that all rubyists
are primadonnas and drama-queens.

------
rurounijones
Note the last "drama" was not to do with yehuda. the page isnt very clear but
it is
[https://github.com/rails/rails/commit/0dd24728a088fcb4ae616b...](https://github.com/rails/rails/commit/0dd24728a088fcb4ae616bb5d62734aca5276b1b)

(the "Last Drama" link, not the RSS links below)

------
yxhuvud
I was a little disappointed when they didn't include the ruckus about Zed not
starting out teaching Array#each. That should probably have earned a spot.

~~~
grandalf
Zed is a clever marketer and that was purely a marketing strategy on his part.
It probably would have cost $20K to get that amount of traffic via AdWords.

------
nicholassmith
In communities where the majority are incredibly passionate about the topic
there's inevitably drama. It's part and parcel of the process.

Although it is amusing that the whole 'MINSWAN' has departed the community
slightly, given that was a big motto for a lot of Rubyists a while back and
part of the reason why learning Ruby was so fun, everyone helped everyone
(mostly).

~~~
anthonyb
If you replace "are incredibly passionate" with "have incredibly huge egos"
then I'd agree with you. I don't see much of this happening in the Python or
Clojure community - they're all too busy programming.

~~~
veemjeem
I don't really think it has anything to do with egos. Maybe this goes back to
steve yegge's conservative vs liberal languages. clojure & python have
communities that are much more conservative than ruby's. Yegge's argument that
python is conservative, is due to google's style guide which forbids
metaprogramming.

Yegge is fairly accurate with his conservative vs liberal rating in regard to
each language community. Compare the type of mailing list posts in golang-nuts
to nodejs; there's definitely more arguments in nodejs than in golang.

~~~
anthonyb
In terms what they can do, Ruby and Python are very similar, yet Python
generates about 1/100th the drama of the Ruby community. I'd say that points
very strongly at ego, or at least the culture of the community. If that
doesn't convince you, have a look at the update at the bottom of this post
from Giles: [http://gilesbowkett.blogspot.co.uk/2012/02/rails-went-off-
ra...](http://gilesbowkett.blogspot.co.uk/2012/02/rails-went-off-rails-why-im-
rebuilding.html)

Python programmers appear to be more welcoming and don't seem to have the same
need to wave enormous meta-programming wangs at each other. Not to say that
metaprogramming isn't useful, but that it's just another tool in the toolbox.
Take mailsnake for example:
[https://github.com/Leftium/mailsnake/blob/master/mailsnake/m...](https://github.com/Leftium/mailsnake/blob/master/mailsnake/mailsnake.py)
Completely classy :)

------
quesera
MINSWAN is now DHHIAJSWAJ.

Being a jerk isn't always the wrong thing to do. But people who are not dhh
propagate the tone without always propagating the situational awareness.

------
jamesu
IMO this site is a nice reminder that no development community is immune from
drama. Every line of code risks controversy. Every interaction has the
potential to turn into a debate. A single action can lead to completely new
ways of thinking.

And really, that's one of the things that makes software development great.

~~~
danso
The thing that made smile most on the site was the "Powered by PHP"

------
timinman
My favorite recent ruby drama was rails including Coffeescript by default:
<https://github.com/rails/rails/compare/9333ca7...23aa7da> (You have to scroll
down for the images)

~~~
jeremyjh
Thanks for mentioning this, very good stuff I never scrolled down to see.

------
yen223
I'd like to see the Python version.

~~~
freyrs3
Honestly I don't see this kind of thing happening in the Python community.
Python devs constantly complain about Py3 and unicode all the time but I don't
think it ever gets to the level of "drama" or vitriol.

------
csmeder
[http://thewebivore.com/why-you-shouldnt-invite-yehuda-
katz-t...](http://thewebivore.com/why-you-shouldnt-invite-yehuda-katz-to-
your-u)

How ironic is it for this person to call out Yehuda and say don't correct
people, when that is exactly what she is doing, she is correcting Yehuda.

If she followed her own advice she would have wrote the blog post about a "un
named" person and maybe waited a few weeks. Instead she is doing exactly what
she is advocating against: Publicly telling some one they are wrong...

~~~
tylermenezes
Read the article. The author is quite explicit that the issue is in the timing
- you don't interrupt DURING a presentation. You're being extremely
uncharitable.

~~~
protomyth
from the comments: bokmann on twitter

I was not the speaker whose demo he redid, but was there with the speaker and
had a similar point in my metaprogramming talk.

Here is the code from my talk, and a new file named 'yehuda_inspiration.rb'
that discusses Yehuda's change to the demo. <https://gist.github.com/1893359>

In short, the other presenter was not wrong... he had a piece of code that was
stylistically different than what Yehuda would have written (see the 'include
vs. extend' comments in that gist. Feel free to read that code example in that
gist and make up your own mind.

I know first hand the other presenter did not take offense to this - although
Yehuda claiming something is wrong when it is solely a style issue is a bit
hubris.

------
mmahemoff
See also: <http://jsdrama.com/>

------
papsosouid
Is any of this stuff actually ruby drama, or all just rails drama? I know the
old ruby community has had a really hard time recovering from being infected
with the rails trash, do they still exist or were they pushed out by the
"rockstars"?


Have Disneyland fans finally reached their limit? - spking
https://www.mercurynews.com/2019/08/13/have-disneyland-fans-finally-reached-their-limit/
======
ilamont
The article neglects to mention the huge drop in international visits to the
U.S. in recent years. Quoting a USA Today article from last week:

 _U.S. visits as a portion of total global travel fell to 11.7% last year from
a high of 13.7% in 2015, according to the travel group and Oxford Economics.
That has resulted in losses to the U.S. economy of 14 million international
visitors, $59 billion in traveler spending and 120,000 U.S. jobs._

Source: [https://www.usatoday.com/story/money/2019/08/09/travel-
inter...](https://www.usatoday.com/story/money/2019/08/09/travel-
international-visits-u-s-forecast-keep-falling/1942922001/)

I know Disneyland and Disneyworld have traditionally been popular destinations
for foreign tourists; it's reasonable to assume that if overall international
travel is down the number of foreign visitors to the parks is also down, even
before factoring in the high prices everyone has to pay to get into the parks.

~~~
stevenjohns
> The article neglects to mention the huge drop in international visits to the
> U.S. in recent years. Quoting a USA Today article from last week:

Part of this might be the ever-stronger US dollar. Five years ago, AUD$1 would
buy about USD$0.94. Now it buys USD$0.68, making the trip to the US about a
third more expensive.

~~~
tortarga
US dollar is pretty much steady against the Euro from 2016 levels. The AUD
fall is because of our mismanaged economy.

The fall in US tourism can better be attributed to Trump trashing America's
foreign image.

~~~
coldtea
As if most tourists care for politics? Changing trends in tourism and
financial issues are far more likely reasons...

~~~
rfrey
As a previously frequent tourist to the US, I assure you politics is an
important consideration for me and my family. Many people of my acquaintance
have also taken politics into account when making vacation plans.

I’m not aware of any studies on this, so anecdote is all I have. But for me,
it’s “obvious” that politics is a factor rather than “obvious” that tourists
only think of trends and exchange rates.

In fact, it’s now common (at least in my circle) for people to plan vacations
to avoid changing planes in the USA, because of the delays in customs and the
risks of missing connections or being denied entry to the US (required in the
USA even if you never leave the transfer area).

~~~
Taniwha
part of the problem is that airports in the US have no "transfer area" \-
international departure lounges are not set up to require passing through
immigration if you want to leave them - many are connected directly to
domestic departure lounges (SFO is an example)

~~~
trianglesphere
It'a not a decision made by US airports, the US requires every person who
lands on US soil to clear US customs even if that person's final destination
is outside the US (ie. the US doesn't allow sterile transit).

~~~
Taniwha
Yes but the US is very unusual in this practice, I don't know of anywhere else
in the Western World where this happens.

~~~
cafard
We traveled a couple of years ago to Milan via Amsterdam. My recollection is
that we did have to clear customs in Amsterdam.

~~~
Taniwha
You were entering the Schengen area - the group of European nations who have a
combined border - once you enter one of those countries you can freely travel
to the others (so no passport booths on the roads on the borders between the
Netherlands and Italy) - your flight from Amsterdam to Milan was an internal
flight.

If you had flown into Amsterdam and transited to Moscow you would have gone
thru metal detectors to the departure lounge, but not thru immigration

------
Aloha
I'm a former Disneyland CM, I strongly suspect lower attendance is a desired
goal.

If my memory is correct, Disneyland can accommodate around 60,000 (aka a 60k
day) without having to shut the gates to prevent further entry - and the park
feels.. well packed - Disney over time has made AP's less viable for frequent
visits to reduce overcrowding, raising ticket prices accomplishes the same
thing, a 45k day with everyone paying an average of 60 bucks a head, is just
as profitable as a 60k day with and average of everyone paying 45 a head. The
difference is the 45k day is a whole lot more pleasant for everyone, and puts
far less strain on park infrastructure, on a 50+ day, an attraction going out
of service puts a tremendous load on other things nearby (vending, merch, and
foods), on a 45k- day, the load is much much less.

for reference, a 50k day by the way, was not abnormal when I worked there in
the early 00's. - and a 55k day was seen weekly or more during summertime.

------
Alex63
It's a tricky trade-off. The last couple of times we visited Disneyland, the
crowds were so bad that it didn't feel worth it. However, I'm not sure I'm
ready to pay $100+ per person per day for less congestion. I think I topped
out at $99.

~~~
notafraudster
This, in addition to the Yogi quote below, is a known problem in game theory:

[https://en.wikipedia.org/wiki/El_Farol_Bar_problem](https://en.wikipedia.org/wiki/El_Farol_Bar_problem)

~~~
cortesoft
This is EXACTLY the type of problem a market economy is designed to solve -
distribution of a scarce resource.

You solve it by setting the price of attendance such that the correct number
of people choose to go.

~~~
habitue
Well, in Disney's case, you want to maximize profits, not optimize attendance
rates. So you set the price such that it maximizes total returns, and whatever
attendance rate that is, is the "correct one"

~~~
mcphage
> So you set the price such that it maximizes total returns, and whatever
> attendance rate that is, is the "correct one"

I don't think it's that simple—they're not trying to maximize total returns on
a single day, but total returns overall. How many people are in the park
determines the kind of experience you have, which then determines if you're
likely to come back. Plus all sorts of associated halo effects—if you enjoy
your time at the park, then after you leave you're more likely to purchase
Disney branded merchandise, watch Disney movies, and subscribe to their
upcoming Disney+ streaming service.

------
ravenstine
I grew up on Disneyland. At one point, my family was going nearly every
weekend because my father worked for a subsidiary of Disney, so we got in for
free. Even for years after he left the company, we bought annual passes and
went rather frequently. Everyone I knew had annual passes.

It's probably been 5 years since I last went. Over time, annual passes became
less worth it. Prices kept going up and more dates kept getting blocked out.
Even ordinary tickets got pricey. Eventually, the park got so crowded that it
really wasn't fun to go. Then they added premiums to a bunch of things like
Fast Passes. I just kind of said screw it and chose not to go back.

I'm sure that I'll go back for some reason, but I won't make an effort to.
This is coming from someone who LOVED Disneyland and wanted to build theme
park rides as a dream job. It ended up feeling like they were doing everything
they could to squeeze pennies, which I know theme parks are designed to do,
but it used to seem like Disneyland at least partly cared about whether or not
you were enjoying yourself. Cast members, at one time, were pretty damned
friendly, though they're still much better than most other theme parks. When I
last went, you could _tell_ that they secretly hated their jobs. I don't want
to pity lowly employees when I'm there to have fun. At least Six Flags doesn't
seriously attempt to make their employees act cheery(I was once an employee
there BTW).

Above all, I really don't want to give Disney money. Sure, they became an Evil
MegaCorp a long time ago, and have long ago slithered their tentacles through
the news and entertainment industry, but they control so much now and pretty
much have no regard for artistry or the cultural significance of their films
and characters. Star Wars just took the cake. Why would I pay Disney for a
bizarro facsimile something I enjoyed _as a child_ where the characters I
loved are losers only to be replaced by modern ripoffs? _Maybe_ they could
have attracted a new generation, which doesn't appear to be working out much
for them, but as someone who grew up with the original Star Wars, what they've
done only repels me from anything to do with them. I'm not even a Star Wars
fan... and I don't think one has to be to respond that way to Disney.

I'm not angry at Disney. It's just that, looking at my own behavior, it's no
surprise to me why attendance to their park would be in decline.

~~~
mdorazio
> Prices kept going up and more dates kept getting blocked out.

> Eventually, the park got so crowded that it really wasn't fun to go.

If prices were going up and attendance was still rising, Disney had two
options: 1) keep raising prices to the point where attendance rates dropped to
a manageable level, or 2) keep prices fixed and put stricter caps on
attendance for specific dates. Being the cutthroat megacorp that it is, Disney
picked option #1 because it's more profitable. If attendance drops enough,
prices will go back down again.

~~~
epylar
3) build more parks?

~~~
delinka
You have to fund that somehow so ... prices go up! Real estate isn't infinite,
but Disney World in Florida is expanding now more than ever. If they ever have
to build a new set of parks elsewhere, real estate prices are going to be
ridiculous, and you have to buy it somehow so ... prices go up!

I don't see how increasing supply brings prices down at Disney - they'll hike
the price now to fund it, then they'll hike prices again to control
attendance.

Buy Disney stock.

~~~
jjulius
>You have to fund that somehow so ... prices go up! Real estate isn't
infinite, but Disney World in Florida is expanding now more than ever. If they
ever have to build a new set of parks elsewhere, real estate prices are going
to be ridiculous, and you have to buy it somehow so ... prices go up!

Why raise prices on consumers when you can fund a new park with the $12.6
billion in profit they earned in 2018?

Edit: I'm not the most fiscally-savvy person, so it would be cool if someone
explained why I might be wrong rather than just hitting the downvote button
and walking away.

~~~
Aloha
Anaheim is landlocked, it would cost them several billion dollars just to buy
more land in Anaheim alone, the odds of more park in Anaheim are basically
zero.

~~~
spking
IIRC, Walt Disney practically begged friends and associates to buy up the land
surrounding Disneyland, and always lamented the cheap motels and
establishments that quickly proliferated outside the park. But he maxed out,
mortgaged and bet pretty much every penny of the studio (and personally) to
get the park built at all. There was simply no money left to buy up any more
orange groves.

------
tempsy
Will be interesting to see how low birth rates will impact theme park
attendance going forward. I feel like young adults are already struggling with
student debt and difficulty affording a home. Throw in a kid or two and makes
me wonder how an average family could afford a 3 or 4 night vacation to
Disneyland with flights and hotel and tickets for everyone. That’s at least
$4k for 4 nights.

~~~
pmorici
I feel like going to Disney is something that the average middle class family
might do once in a life time. At least that is how it was in my family growing
up in the 80's and 90's we went to Disney World once and every other vacation
was some variation on camping at a state park or going to the local Six Flags
amusement park for the day. When you look at it that way 4k doesn't seem as
outrageous.

~~~
cortesoft
Probably depends on where you are. As a California native, Disneyland trips
were much more frequent.

------
nerfhammer
What do these prices actually look like? the article does not get into
specifics about how much it actually costs or how much it used to cost.

~~~
robbiet480
Ticket price is based on age, demand, number of days you want to visit and
included features (park hopper and MaxPass). The cheapest, adult, lowest
demand, 1 day, no features ticket runs $104 right now. The most expensive peak
time, single day ticket with park hopper and MaxPass is $214.

Annual passes provide extra benefits over tickets and are priced based on what
days you wish to be able to go (cheaper passes have more blockout dates or are
limited to southern California residents only). AP runs from $599 for Flex
(only allowed in certain parks and sometimes must reserve park entrance in
advance) to $1399 for the Signature Plus which has 0 blockouts or
restrictions. (There is also the Premier passport which costs $2,099 and gets
you unrestricted access to both Disneyland and Walt Disney World in Florida.)

~~~
ilamont
For a vacationing family of 4 coming to the park for three full days and
staying in a Disney resort for 4 nights in the spring or summer, what might be
the expected cost range including everything (except for flights and the
rental car)?

~~~
robbiet480
It really depends on what hotel you are staying at, whether on or off
property. On property you could pay anywhere from $3000 to $5000 would be my
guess off the top of my head. Paradise Pier is lowest price, Grand Californian
is highest. Really depends on when exactly you are going too. I've seen prices
like $1200/night at Grand Californian during Christmas time.

Disneyland's website has an excellent tool to calculate full price (even
including flights). I'd recommend checking that out or calling them for a more
personal touch. You can book everything online (tickets, hotels, transport
from the airport to the resort, dining and more).

~~~
ilamont
Thanks. I wasn't interested for my own family, just curious about what people
typically pay for the experience these days.

FWIW I went to Disneyland and Universal Studios in 1980 with my family, and it
really was a special experience - still remember the trip 40 years later.

------
tempsy
I’d be curious how it compares to Universal Studios Hollywood. Personal
observation is that Universal Studios has gotten better, faster (with recent
addition of Harry Potter area) and is more fun/interesting for the older
crowd. If you had to choose one or the other because both are expensive then
Universal Studios seems like a better option unless you have very young kids.

~~~
polalavik
Haha not a chance. For the price Universal Studios is incredibly small, less
well kept, and there’s only really 1-2 interesting rides. The whole park takes
like 10 minutes to walk end to end. You can walk around Disney land all day
and still not hit it all.

~~~
tempsy
“Not a chance” what?

Looking at 2018 data Disneyland grew attendance 2% vs Universal Studios at
12%, and the source says almost all attributed to Harry Potter.

Both parks can be done in a day each...both are small relative to Orlando
counterparts.

[http://www.ocregister.com/disneyland-still-worlds-
no-2-theme...](http://www.ocregister.com/disneyland-still-worlds-no-2-theme-
park-but-universal-studios-hollywoods-attendance-surges)

~~~
ap3
You can do Disneyland in a day if it’s not too crowded

Universal Studios’ AP is a lot cheaper but the park needs to add a lot more
rides to match Disneyland

------
oceanghost
TBH, I feel uniquely qualified to comment on this.

I lived two miles from Disneyland for a decade (Old Towne Orange). I proposed
to my wife there (now ex-wife). We named our daughter after the "Emma" from
"Once Upon a Time." We had an annual pass for about a decade, and my life and
free time centered around Disneyland.

For years I went to DL/DCA several times a week. But, gradually, it became a
horrid thing. Disneyland, when I arrived in the early 2000s was a place where
I could forget the stresses of the daily world. I worked so close to it
(Cypress and Santa Ana), that I would sometimes take an extended lunch and
ride one or two rides and then go back to work.

Psychologically, Disneyland was a place that allowed me to let go and enjoy
myself.

Then, they started offering financing on their Annual Passes. I used to have
to layout 1k for my families passes. But now, you could get them on an
installment basis. The parks were always crowded, and even when they weren't,
the powers that be understaffed the park such that ride times were long. I had
a friend who could barely afford food but had a $400 AP. She would often crash
in our living room to go to the park.

What was once my refuge from reality became this horrid thing where we were
waiting 60 mins for a 90-second ride. The last two years the (ex)wife and I
had passes, we just, would stand in line, look at each other, and think, "Why
are we here? We could be at home, not standing in the sun, not paying $7 for a
bottle of water." We weren't enjoying ourselves, and it cost us about 1k/yr
for the passes and parking, plus incidental expenses in the park.

The company I used to work for was located a couple of miles from Dl, and when
we had guests from other countries, I would take them to Disneyland. It was an
amazing thing for the folks because I could give them a world-class tour of
the park (being a regular), and we would all have a great time. But gradually,
that became impossible.

I remember the exact day I gave up on Disneyland. We drove over there, and
they were doing some construction, and detour, after the detour, we ended up
at some nearly abandoned mall, which is only a little bit from my house, then
we had to board a bus which drove us to the transportation hub. It took 75
mins to get into the park, and the whole time, I was literally one exit from
my home. It took 75 mins for us to get to the front gate back to our car.
Never again.

While my failures as a husband are my own fault, and my marriage was probably
doomed from the beginning... In a real way, my marriage was based on
Disneyland. It was something my wife and I bonded over and looked forward to
and, was special to us. When we stopped going, the magic in our relationship
died.

Someday I'll go back, but not today, and not anytime soon. I live 100 miles
from Disneyland now. If it were enjoyable again, I'd move back to Orange
County. But it's not. Disneyland is a broken dream, and their tilt towards
Star Wars is a joke that is not funny. Disney must constantly reinvent itself,
and the last decade has been a mistake.

I interviewed for Disney Research a year ago and, was amazed by the brilliant
folks working there. Ultimately, Disney will prevail just because of the
amazing folks who work there. I don't know if I'm just an old fart wishing for
his more formative years, or if things are really different.

Anyways, I love you Disneyland. I hope we can both get our act together. But
you've broken my heart and I'm weary.

~~~
ravenstine
> In a real way, my marriage was based on Disneyland. It was something my wife
> and I bonded over and looked forward to and, was special to us. When we
> stopped going, the magic in our relationship died.

Damn. :(

I had a similar situation with my last relationship, except we broke up soon
after we decided to go to Knott's Berry Farm for the first time instead.

 _(no joke, not that it had anything to do with the breakup, but kind of a
funny coincidence)_

~~~
oceanghost
Knotts has been a disaster even longer than DL. My grandmother used to work
there and take my brother and I regularly. I don't even think it's safe, to be
honest. Whatever I might say about Disneyland, at least it's safe.

Sorry about your bad luck.

~~~
Aloha
I think Knotts is about as safe as it ever has been, I'm saying this as
someone who worked at both Knotts and Disney, Knotts in some ways in the early
and mid 00's was actually better about doing some basic maintenance to keep
the park looking and feeling fresh.

~~~
oceanghost
The last time I ever went to Knotts, admittedly 13 or so years ago... One of
the employees asked me not to lean on a chain that was strung between to parts
of the que to rope it off. I gave him a sort of, "Are you serious?" look...

He was super nice and explained that it took him a whole year to get the
chain, that Knotts doesn't like paying for things like that, and he didn't
want it, or the que itself damaged as he wouldn't be able to get a new one
anytime soon.

My mind immediately started thinking about the cost of chains, and how safe
the park could possibly be if that were the operating environment. We rode the
ride because we'd waited 4 hours in the queue, and the friend that I had gone
with and I agreed this was not a place we wanted to be anymore.

I also worked in Cypress, a few blocks from Knotts, and we'd always hear about
horror stories about people stranded on attractions. What worried me about it
most was, not that rides break down, they do. What was concerning was that
Knotts didn't seem to have a plan for that.

When a ride breaks at Disneyland, They have plan after plan after plan. I have
never felt unsafe at Disneyland, and I've had at least half a dozen incidents.
I remember being stuck once on the Ferris wheel at DCA. My wife and I were
stuck with 3, 13-year-old boys for 2 hours. We joked around, got to know each
other other, assigned the barf bags to those most likely to need them-- the
sunwheel is 160ft tall. Never felt unsafe for even a moment.

Knotts, just seems to call the fire department when something happens.

------
jdswain
Theres some simple economics in this. If visitor numbers are down 3%, and say
prices are up 5% then total profit is also up, variable costs are down, and
parks are less crowded so everyone has a better time.

------
ap3
Went last week, very disappointed by the new Star Wars attraction, essentially
a glorified video game - I’ll be skipping Star Wars land next time

------
yding
Surprise! The laws of economics still apply to you, even if you're a company
with a great brand like Disney and Apple.

------
cylinder
Or more like, the USD is extremely overvalued right now. In addition, the US
makes travel to the US extremely risky and difficult, even for visa waiver
eligible applicants. Many people are starting to not bother.


Literate Commits (2016) - pcorey
http://www.petecorey.com/blog/2016/07/11/literate-commits/
======
simonw
I went through a phase a few years ago of writing ESSAYS in my commit
messages, on the basis that they were the only form of documentation which I
trusted to stay 100% synchronized with the code.

Eventually I realized that there's a better way to do this: keep your
documentation in the same repo as your code, and construct commits that update
the documentation AND the tests AND the code all in the same unit. Now your
commit message can be much shorter, but you still guarantee that the
documentation is exactly aligned with the code that it talks about.

It also means you can add unit tests that check that code is covered by your
documentation! [https://simonwillison.net/2018/Jul/28/documentation-unit-
tes...](https://simonwillison.net/2018/Jul/28/documentation-unit-tests/)

~~~
lytedev
Just to bring up a neat point, this doesn't guarantee that the documentation
and the code are the same, as you could change code without updating
documentation.

A very slick way of enforcing this that I've seen is having actual unit tests
in your documentation (and of course a CI tool to enforce that tests pass).
This is something that I think is extremely cool about Elixir! It forces you
to think about testing, documentation (with ACTUAL examples!!), and the
problem you're solving all at once. It's a very neat concept.

[https://elixir-lang.org/getting-started/mix-otp/docs-
tests-a...](https://elixir-lang.org/getting-started/mix-otp/docs-tests-and-
with.html#doctests)

~~~
sambal
Python and Rust go the “documentation test” route as well.

Go goes the opposite direction with “testable examples” that are written
alongside test code and added to generated documentation.

[https://docs.python.org/2/library/doctest.html](https://docs.python.org/2/library/doctest.html)

[https://doc.rust-lang.org/rustdoc/documentation-tests.html](https://doc.rust-
lang.org/rustdoc/documentation-tests.html)

[https://golang.org/pkg/testing/#hdr-
Examples](https://golang.org/pkg/testing/#hdr-Examples)

------
mannykannot
One of the biggest difficulties in understanding a code base is in identifying
the implicit contracts and constraints that exist between the various parts.
Each time a feature is added, a fix is made, or some aspect is refactored,
some information about the set of things involved in the implementation of
that aspect is revealed. If your commits are usually each about one thing
only, and their comments simply allow you to identify all the commits needed
for a given change, you have already gone a long way towards making that
information useful - it's the single-responsibility principle applied in a
different area.

------
shadowfiend
I poked at this concept myself with a short-lived old side project called
sophocles:
[https://github.com/Shadowfiend/sophocles](https://github.com/Shadowfiend/sophocles)
. At the time I was experimenting with displaying the diff and the commit
message side-by-side, as well.

This post says:

> I’m not advocating using literary commits in real-world software

But I think variations of the underlying thinking are very important for real-
world software, even if it's not the exact same thing. Brain dumped this
around the time I was working on sophocles at
[http://shadowfiend.posthaven.com/using-commit-messages-
for-d...](http://shadowfiend.posthaven.com/using-commit-messages-for-
documentation) , and it's still a core part of how I develop software and how
I want the teams around me to as well.

------
tobr
This seems very sensible, and completely at odds with the common “best
practice” of keeping commit messages short. I find that the best way to
understand why a piece of code is the way it is is not through comments in the
code, but by looking at history and commit messages. They are comments where
it’s completely clear what code they describe, even if it’s spread out across
the code base, and even if the code has since been changed to the point where
the comment is no longer applicable.

~~~
UK-AL
Commit titles should be short.

Commit messages are often small essays. Especially in the Linux kernel

~~~
gunnihinn
Yeah. I’ve never been unhappy with reading a long commit message.

------
JoelMcCracken
I've thought about this a good bit independently, and I want to be able to do
a few things:

\- Add line-change/diff-specific commentary. This needs to be within the
context of a larger commentary/set of changes, as usually the changes are not
independent, and in fact relate to simultaneous constraints which inform your
chosen solution.

\- Add some structure to a list of commits in a branch. I'd like a hierarchy,
in fact. I've thought about trying to emulate this by making sub branches and
then merging them into a parent branch, but it seemed like it would be a big
pain.

Anyway, I've love to see some software that could help with this!

------
jostylr
I wonder if the Peter Norvig comment mentioned in that article about the
different pathways is what led to my idea of stepping past literate-
programming and into a concept I call pieceful-programming; I had just had
back surgery when I read the John Cook article and perhaps it filtered deep in
the subconscious.

While I am still working on my pieceful implementation, the hope is to very
much elevate the role of the pieces and ideally generate graphs relating to
all the pieces that might have code, tests, various documentations related to
the pieces, all being woven into their separate compilation targets.

------
stinos
Sort of an interesting idea, and I wholehartedly agree with

 _ensuring that each and every commit serves a singular purpose and adds to
the narrative history of the project has done wonders to reduce thrash and the
introduction of “stupid mistakes”._

 _Read in chronological order, these commits should paint a clear picture of
how and why this particular code came into existence and how it has changed
over the course of its life._

I'm not sure if this is particular to 'literate', to me it sounds more like
common sense, but yes: that is how I like commit history.

The example [https://github.com/pcorey/delete-occurrences-of-an-
element-i...](https://github.com/pcorey/delete-occurrences-of-an-element-if-
it-occurs-more-than-n-times/commits/master), even though the OP mentions it's
a toy, illustrates this pretty well. Without knowing much about the code you
can just read the commit messages and even though the style of the text is a
bit too fuzzy for my liking at times (i.e. lots of words just to form nice
prhases to make points which could be made with shorter and more to-the point
sentences) there is a much larger problem (imo): the first line of each commit
makes no sense whatsoever wrt what actually changed in the code. This makes it
impossible to at first sight (in git user interfaces which use the first line
in their commit lists, i.e. the vast majority I think) find out what is
happening and what a particular commit does. If that is an articfact of
literate commits, then sorry but that is just not very good. Here's an
excerpt:

        # Getting Real
        # Forging Ahead
        # Keep it Simple
        # Our First Test
        # Take What We're Given
        # Laying the Groundwork

Suppose you come back to this knowing you changed something in a recent commit
and want to look it up. My strategy is then usually to just glance over the
history for a few seconds to see if I can immediately find the commit I'm
looking for before starting an actual search. Works very, very often. Not so
much in this case. Compared to what I'm looking at right now in a repository
of a team I work with:

        converters: Fix nullable double getting converted into NaN
        plot: Use assembly reference instead of project reference
        plot: Update code style and formatting
        network: Add functions for element acces to Python scripting API

The body of the commit message then goes on describing more detail and usually
also _why_ the change was made. As such creating the narrative the OP talks
about. But with the added benefit that the message header provides pretty good
insight into what a commit does, hereby providing some kind of index to the
book being written, making it much easier to discover things.

~~~
pcorey
Yeah, I agree that the subject of those commits are far from helpful or
descriptive. To be honest, they were written as cheeky subheaders for the
generated example article, and don't even do a job there.


The algorithms that detect hate speech online are biased against black people - SeanBoocock
https://www.vox.com/recode/2019/8/15/20806384/social-media-hate-speech-bias-black-african-american-facebook-twitter
======
Causality1
Disappointed to see there was no manual comparison of the automated results to
the actual statistics of the tweets. The article mentions several times that
both automated and manual tweet reviewing flagged more tweets from black
people as hate speech but there was no attempt to quantify exactly how much
hate speech each group generated. Tweets by African-Americans were 1.5x as
likely to get flagged as offensive but, hypothetically, if it happened to be
the case that African-Americans were 1.5x as likely to engage in hate speech
neither the researchers or article readers would know about it. Not that
that's the case, but do some due diligence.

------
rasz
Wouldnt the more correct title be "African-Americans 1.5x as likely to use
racial slurs"?


Ask HN: What do we do with an iPad app built on a recently shutdown Google API? - thegrossman

My coworker and I have spent the last few months building an iPad app on top of the Google News API, which has just yesterday been slated to shutdown: http://code.google.com/apis/newssearch/
We were motivated to create the app based on a lack of quality "hard news" sources (for lack of a better term) on the iPad. There is no shortage of "social" news apps such as Flipboard and Pulse, and there exist a slew of quality RSS readers (Reeder is indispensable to me). But I also crave conventional, un-sexy, non-web2.0 journalism; a simple reporting of the news of the day.
I used to spend obscene chunks of my day parked on CNN.com, click the refresh button incessantly... before the quality of their reporting diminished. And while there are iPad apps for individual news outlets (the NY Times, CNN, etc all have their own apps), the great thing about Google News is the fact that they aggregate content from news outlets around the word, from the Times to Al Jazeera to my tiny local newspaper.
Google News doesn't have a spectacular web interface, especially when accessed on the iPad. We thought we could do better... and purely for our own use (at first), we built an app on top of their API. At this point it's 80% completed; here are some screenshots:
https://s3.amazonaws.com/jackadam_broadsheet/broadsheet.jpg
Now that the API is being shut down, we have an app with no data source. What do we do? On top of spending all that development time seemingly for naught, we love using our app, and don't want to go back to the old way!
So we're making an appeal to the HN community, in search of creative ideas on how to proceed.
We haven't been able to find any great news API alternatives. Yahoo News recently shut down their news API, and the Bing news search is missing a couple critical features. But maybe there are others?
[Also: I'd like to keep the conversation pragmatic and avoid the (perfectly valid) question of whether it's wise to build an app entirely reliant on some third party's good graces.]
======
maresca
_We haven't been able to find any great news API alternatives._

 _avoid the (perfectly valid) question of whether it's wise to build an app
entirely reliant on some third party's good graces._

In my opinion, it isn't wise to build an app entirely reliant on a 3rd party
API. Looking for a new API to migrate to says you haven't learned from the
mistake you made. I've made the same mistake with an attempt at a SMS to
Social Message tunnel on facebook/myspace back in the day. Then facebook made
it a native feature. It was an important lesson to learn.

If I were you guys, I'd stop looking for APIs and start building your own
backend. This way, you can pull in more than one source of data. Also remember
that there are other ways of getting data.

------
NonEUCitizen
Build your own backend so you can declare independence.

~~~
MatthewPhillips
I think building your own backend before you have funding when a simple API is
available is a pretty bad idea. You don't know if your site/app will ever hit
critical mass, why waste the time and money in building an elaborate backend
system when you can develop that down the road when/if you have something
worthwhile on your hands.