git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: pushing branches

From
Thiago Farina <tfransosi@gmail.com>
Date
Jul 21, 2012, 02:10 UTC
Message-ID
<CACnwZYdUzk74znPs4F+xz3haA3QhA9-DbR3mWWEVMfnztp-oCA@mail.gmail.com>
In-Reply-To
<CAJsNXT=-Ap0zJqK2F_3uJ7secmq7uvnSc218x+NoYdO5pLJAMg@mail.gmail.com>

On Fri, Jul 20, 2012 at 10:58 PM, PJ Weisberg <pj@irregularexpressions.net> wrote:

Show 8 quoted lines
> In your original email, you had one command that did what you wanted
> and one that didn't.
>
> $ git push origin master
> $ git push origin feature-work
>
> Can you spot the difference between them?
>
Do'h, now I can see the idiocy that I was doing.

If I'm understanding this better, $ git push origin master tells git to push to remote origin, the contents of my master branch.

And then,

$ git push origin feature-work tells git to push to remote origin to push the contents of feature-work branch.

Hence does not make sense to ask git to do "push origin master" while inside feature-work branch.

Show 8 quoted lines
> Like Konstantin said, you can look into the different options for
> push.default, but don't expect Git to push one branch when you told it
> to push another.
>
> -PJ
>
> Gehm's Corollary to Clark's Law: Any technology distinguishable from
> magic is insufficiently advanced.
Previous: PJ WeisbergNext: Junio C Hamano
Message 7 of 13 in “pushing branches”
  1. Thiago FarinaJul 20, 2012
  2. Junio C HamanoJul 20, 2012
  3. Thiago FarinaJul 20, 2012
  4. PJ WeisbergJul 20, 2012
  5. Thiago FarinaJul 21, 2012
  6. PJ WeisbergJul 21, 2012
  7. Thiago FarinaJul 21, 2012
  8. Junio C HamanoJul 21, 2012
  9. Thiago FarinaJul 22, 2012
  10. Junio C HamanoJul 22, 2012
  11. PJ WeisbergJul 20, 2012
  12. Konstantin KhomoutovJul 20, 2012
  13. Matthieu MoyJul 20, 2012

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.