There are a dozen similar questions, with everyone posting long answers trying to talk the asker out of it.
Is it possible to create a branch in such a situation?
I do not want to clone the repo, just so that I can create a branch in that copy's working directory, push it, and then delete the whole thing again. The script that will create this branch (after checking to see if it exists) already has access to the bare repo in Gitolite and can issue the commands directly. "git checkout" complains that the operation must be performed in a work tree.