{"thread":{"id":"29118","subject":"configure git to not push all remote tracking branches","startedAt":"2011-12-09T15:00:13Z","lastAt":"2011-12-09T15:07:50Z","messageCount":3,"participants":["Justin Johnson","Ramkumar Ramachandra"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"180656","messageId":"CAPD5EOjsu-9=CCUJut_bGqv=asp8FeGqL2GhKewgw3SQsArk_A@mail.gmail.com","threadId":"29118","inReplyTo":null,"subject":"configure git to not push all remote tracking branches","fromName":"Justin Johnson","fromEmail":"justin.johnson3@gmail.com","sentAt":"2011-12-09T15:00:13Z","receivedAt":"2011-12-09T15:00:13Z","isPatch":false,"sender":{"key":"justin.johnson3@gmail.com","avatar":null},"body":"Hi, I'm looking for some help with pushing to remote repositories.\nI accidentally left out the refspec from my git push command and git\npushed all branches that are set up to track the remote repo that I\nspecified. I would like to disable this, and enforce specifying a\nrefspec. Is there a way to do this?\ne.g.\ngit push alternateorigin\nshould not do anything, but\ngit push alternateorigin mybranch\nshould push just mybranch.\n--\nJustin Johnson\n"},{"id":"180657","messageId":"CALkWK0m0f-AGLwKqiKx9Aozwr5oN6FrH5ehG03mmEpB7Di8PWQ@mail.gmail.com","threadId":"29118","inReplyTo":"CAPD5EOjsu-9=CCUJut_bGqv=asp8FeGqL2GhKewgw3SQsArk_A@mail.gmail.com","subject":"Re: configure git to not push all remote tracking branches","fromName":"Ramkumar Ramachandra","fromEmail":"artagnon@gmail.com","sentAt":"2011-12-09T15:03:55Z","receivedAt":"2011-12-09T15:03:55Z","isPatch":false,"sender":{"key":"r@artagnon.com","avatar":"https://avatars.githubusercontent.com/u/37226?v=4"},"body":"Hi Justin,\n\nJustin Johnson wrote:\n> git push alternateorigin\n> should not do anything, but\n> git push alternateorigin mybranch\n> should push just mybranch.\n\n$ git config push.default nothing\nNote: push.default defaults to \"matching\"\n\nCheers.\n\n-- Ram\n"},{"id":"180658","messageId":"CAPD5EOgeKpV1bWJZmdUR6ZQuA=objSAApVrz1W9W8C_ij+XN9A@mail.gmail.com","threadId":"29118","inReplyTo":"CALkWK0m0f-AGLwKqiKx9Aozwr5oN6FrH5ehG03mmEpB7Di8PWQ@mail.gmail.com","subject":"Re: configure git to not push all remote tracking branches","fromName":"Justin Johnson","fromEmail":"justin.johnson3@gmail.com","sentAt":"2011-12-09T15:07:50Z","receivedAt":"2011-12-09T15:07:50Z","isPatch":false,"sender":{"key":"justin.johnson3@gmail.com","avatar":null},"body":"On Fri, Dec 9, 2011 at 10:03 AM, Ramkumar Ramachandra\n<artagnon@gmail.com> wrote:\n> Hi Justin,\n>\n> Justin Johnson wrote:\n>> git push alternateorigin\n>> should not do anything, but\n>> git push alternateorigin mybranch\n>> should push just mybranch.\n>\n> $ git config push.default nothing\n> Note: push.default defaults to \"matching\"\n>\n> Cheers.\n>\n> -- Ram\n\nThank you, that's exactly it. I saw it in the docs for git-config but\nwasn't positive that's what I needed.\n\n--Justin\n"}]}