github/hub — pull request #476 by mislav (2014-02-05 00:35:09+00:00)
Title: gh: Trash `script/*` scripts in favor of Makefile

The current `script/bootstrap` and `script/build` are unfriendly to Go newbies because they require:

- The user having a GOPATH (I didn't understand why I need one at first)
- The user having `godep` (later I figured out it's not needed since we bundle deps in git)
- The user having `hg` to fetch godep
- `script/build` would try building even if `script/bootstrap` failed (generating confusing error messages)

Ideally, the build process should work even if the user doesn't have any of that. This changes `script/bootstrap` to simply check environment for prerequisites (go 1.2, make), and relies on `make hub` for the build process. Ideally `bootstrap` would prepare the environment completely, but we can't install Go and make on the behalf of the user.

I wrote a [dumb Makefile](https://github.com/github/hub/blob/c05272dd93c9408a0bcea19cfdf43b3c17966e2e/Makefile#files). It's probably not perfect but it gets the job done. It was a part of my learning process how to compile Go programs. Only later I've seen that `script/make` implements the no-dependencies build process that I wanted (that could've saved me hours of learning!).

/cc @jingweno