Information Technology Reference
In-Depth Information
How It Works
The one strange thing that happens in this recipe was already mentioned in Recipe
10-6. After you delete the remote branch in step 5 with:
$ git push origin :new-web-interface
The $ git branch -a -vv command prints:
* master
59de3b0 [origin/master] z
new-web-interface
59de3b0 [origin/
new-web-interface] z
remotes/origin/HEAD -> origin/master
remotes/origin/master 59de3b0 z
This means that the new-web-interface branch is still the local tracking
branch. It tracks the origin/new-web-interface branch that doesn't exist any-
more. We solve this discrepancy by removing the new-web-interface branch
completely in step 6.
10-12. Pushing to non-bare repositories
Problem
You work in a repository that was cloned from a non-bare repository. You want to push
to the original repository even though it is not a bare repository. In this recipe we will
use two repositories:
johns-repo —a non-bare repository you commit into
public-repo —a non-bare repository you push to
Solution
Create a new directory with:
Search WWH ::




Custom Search