Switching from `make alpha` to `make nightly` doesn't work
Switching from make alpha to make nightly gives this error:
updating: mac-langpacks/pt-BR.xpi (deflated 10%)
You are not currently on a branch.
Please specify which branch you want to merge with.
See git-pull(1) for details.
git pull <remote> <branch>
Makefile:97: recipe for target 'prep-nightly' failed
make: *** [prep-nightly] Error 1
This can be traced to this: https://gitweb.torproject.org/builders/tor-browser-bundle.git/tree/gitian/fetch-inputs.sh#n258
Because make alpha
checked out a tag, git pull
fails. We can detect a checkout tag with something like git status | grep "HEAD detached"
and behave more intelligently.