Community
Participate
Working Groups
From bug 431872 comment 2: I was working on a local feature branch, which is configured for push/pull against a same-named branch on origin. When I dared to click "Commit and Push" I assumed the configuration of this branch would be used. Unfortunately the global "HEAD to origin/master" configuration was used and all my dirty WIP appeared on master <BLUSH> I would always assume the configuration for the currently checked out branch to have precedence over any global configuration, no? Yes I know, clicking "Commit and Push" may be a bad idea to begin with ... maybe that button should be disabled on any branch that's not based on origin/master ...
Created attachment 245663 [details] .git/config Here's my (lengthy) .git/config Relevant branches are master sherrmann/ExternalAnnotations for your convenience the corresponding entries are [branch "sherrmann/ExternalAnnotations"] remote = origin merge = refs/heads/sherrmann/ExternalAnnotations [branch "master"] remote = origin merge = refs/heads/master rebase = true This is what seems to have taken precendence: [remote "origin"] url = ssh://sherrmann@git.eclipse.org/gitroot/jdt/eclipse.jdt.core.git fetch = +refs/heads/*:refs/remotes/origin/* fetch = refs/notes/*:refs/notes/* pushurl = ssh://sherrmann@git.eclipse.org/gitroot/jdt/eclipse.jdt.core.git push = HEAD:refs/heads/master Not, sure if the remote section should contain a push entry for the feature branch, too? But I don't want all my pushes to also push the feature branch. Also, I did select "[x] configure branch for push and pull" (quoted from memory) when I first did "Push Branch". The "HEAD:refs/heads/master" entry is handy for all the short-lived, purely local branches, that should never show up on the server.
See bug 441938 comment 6 for how this would be properly fixed. I added it as a dependency.
[Batch change] Remove pre-3.7 Target Milestones If anyone on CC list is going to fix/implement this, please assign a new 3.7+ target milestone.
*** This bug has been marked as a duplicate of bug 431872 ***
Clicked the wrong button in the wrong screen... :-(
*** Bug 578607 has been marked as a duplicate of this bug. ***
New Gerrit change created: https://git.eclipse.org/r/c/egit/egit/+/190775
Gerrit change https://git.eclipse.org/r/c/egit/egit/+/190775 was merged to [master]. Commit: http://git.eclipse.org/c/egit/egit.git/commit/?id=6af9d7b33919c4a9d6259546d4d5e4800c70cdac