Be more clever about finding hh_server and handling errors
commita323bf343d37eb1fef61d4e2d8d764052010b57e
authorJosh Watzman <jwatzman@fb.com>
Thu, 3 Apr 2014 17:46:15 +0000 (3 10:46 -0700)
committerSara Golemon <sgolemon@fb.com>
Fri, 4 Apr 2014 17:04:28 +0000 (4 10:04 -0700)
tree169ff069864acab0217246421e8447987ebe70b9
parentf9af3076f13763773bec39788b7ce86a5416aa6c
Be more clever about finding hh_server and handling errors

It was suggested internally a while ago that `hh_client` should
first look for an `hh_server` sitting right next to it, so you don't
have to muck with your `$PATH`. That's not hard to do, let's do it. Also
remove the very outdated `HH_HOME` mechanism I don't think anyone uses
anymore. If there isn't an `hh_server` next to the client, still try searching
the `$PATH`, because well why not. Needing to have everything on the
`$PATH` has already confused one person externally who was building from
source :\

While I'm at it, handle the case where we can't find `hh_server` a
little more gracefully than just trying to start it up in a loop while
`/bin/sh` yells on the terminal.

Reviewed By: @pikatchu

Differential Revision: D1254953
hphp/hack/src/client/clientStart.ml