git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Miles Bader <miles@gnu.org>
To: Jay Soffian <jaysoffian@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: set-upstream for existing branch...?
Date: Thu, 17 Feb 2011 16:11:37 +0900	[thread overview]
Message-ID: <buo8vxfxhhy.fsf@dhlpc061.dev.necel.com> (raw)
In-Reply-To: <AANLkTikqj8NjLwR647E1tHUuDO=OitUJ1dm5Fs7gtXXt@mail.gmail.com> (Jay Soffian's message of "Thu, 17 Feb 2011 02:08:55 -0500")

Jay Soffian <jaysoffian@gmail.com> writes:
> On Thu, Feb 17, 2011 at 12:19 AM, Miles Bader <miles@gnu.org> wrote:
>> Is there a convenient, intuitive, way to set (or change) @{upstream} for
>> the current branch, without doing anything else...?
>
> $ git branch <current_branch> --set-upstream <new_upstream>
>
> But note that this is deceptive: what's important is the relative
> positions of <current_branch> and <new_upstream> on the command-line,
> and they must be in that order. It doesn't (currently) matter where
> you place the --set-upstream.
>
> I've got it on my todo list to make --set-upstream take <new_upstream>
> as its argument so that you can just say:
>
> $ git branch --set-upstream <new_upstream>

Thanks, the latter sounds nice, but for now the former is good for an alias...

-miles

-- 
Dictionary, n.  A malevolent literary device for cramping the growth of
a language and making it hard and inelastic. This dictionary, however,
is a most useful work.

  reply	other threads:[~2011-02-17  7:11 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-17  5:19 set-upstream for existing branch...? Miles Bader
2011-02-17  7:08 ` Jay Soffian
2011-02-17  7:11   ` Miles Bader [this message]
2011-02-17  7:24     ` Miles Bader
2011-02-17  7:45       ` Jay Soffian
2011-02-17  8:23       ` Michael J Gruber
2011-02-17  9:25         ` knittl
2011-02-17  9:41           ` Michael J Gruber

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=buo8vxfxhhy.fsf@dhlpc061.dev.necel.com \
    --to=miles@gnu.org \
    --cc=git@vger.kernel.org \
    --cc=jaysoffian@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).