Downloading should start from the original URL at github.com and follow redirects. In the future, who knows if codeload.github.com will even be a thing? So, roughly:

```
rm -rf /tmp/hub
curl -fsSL https://github.com/github/hub/archive/v1.11.2.tar.gz | tar -x -C /tmp/hub --strip-components=1
cd /tmp/hub && rake install
```