From: Matthieu Moy <Matthieu.Moy@grenoble-inp•fr>
To: "Carlos Martín Nieto" <cmn@elego•de>
Cc: git@vger•kernel.org, jrnieder@gmail•com, gitster@pobox•com
Subject: Re: [PATCH 1/3] branch: introduce --set-upstream-to
Date: Tue, 10 Jul 2012 19:08:35 +0200 [thread overview]
Message-ID: <vpq394zo86k.fsf@bauges.imag.fr> (raw)
In-Reply-To: <1341939181-8962-2-git-send-email-cmn@elego.de> ("Carlos Martín Nieto"'s message of "Tue, 10 Jul 2012 18:52:59 +0200")
Carlos Martín Nieto <cmn@elego•de> writes:
> The new options allows us to type
>
> git branch --set-upstream-to origin/master
This is cool :-).
> Documentation/git-branch.txt | 9 ++++++++-
> builtin/branch.c | 15 +++++++++++++--
I think this deserves a few new tests (probably in t/t3200-branch.sh).
> +-u <upstream>::
> +--set-upstream-to=<upstream>::
> + Set up <branchname>'s tracking information so <upstream> is
> + considered <branchname>'s upstream branch. If no branch is
> + specified it defaults to the current branch.
Perhaps "if <branchname> is not specified, then it defaults to the
current branch.". The current wording does not make it very clear if "no
branch is specified" refers to <branchname> or <upstream> (although the
second option would be plain silly).
> + } else if (new_upstream) {
> + struct branch *branch = branch_get(argv[0]);
> +
> + if (!ref_exists(branch->refname))
> + die(_("branch '%s' does not exist"), branch->name);
Indentation (2 spaces -> tab).
--
Matthieu Moy
http://www-verimag.imag.fr/~moy/
next prev parent reply other threads:[~2012-07-10 17:08 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-10 16:52 [PATCH 0/3] A better way of handling upstream information in git-branch Carlos Martín Nieto
2012-07-10 16:52 ` [PATCH 1/3] branch: introduce --set-upstream-to Carlos Martín Nieto
2012-07-10 17:08 ` Matthieu Moy [this message]
2012-07-10 17:26 ` Junio C Hamano
2012-07-10 19:13 ` Jonathan Nieder
2012-07-10 19:49 ` Junio C Hamano
2012-07-10 20:11 ` Jonathan Nieder
2012-07-10 20:49 ` Junio C Hamano
2012-07-10 21:09 ` Jonathan Nieder
2012-07-10 23:13 ` Junio C Hamano
2012-07-10 23:47 ` Jonathan Nieder
2012-07-11 1:20 ` Junio C Hamano
2012-07-11 1:37 ` Jonathan Nieder
2012-07-12 8:41 ` Miles Bader
2012-07-12 16:58 ` Junio C Hamano
2012-07-10 16:53 ` [PATCH 2/3] branch: suggest how to undo a --set-upstream when given one branch Carlos Martín Nieto
2012-07-10 17:20 ` Matthieu Moy
2012-07-11 13:50 ` Carlos Martín Nieto
2012-07-10 17:40 ` Junio C Hamano
2012-07-11 14:24 ` Carlos Martín Nieto
2012-07-10 19:24 ` Jonathan Nieder
2012-07-10 22:43 ` Junio C Hamano
2012-07-10 23:00 ` Jonathan Nieder
2012-07-11 15:14 ` Carlos Martín Nieto
2012-07-10 16:53 ` [PATCH 3/3] branch: add --unset-upstream option Carlos Martín Nieto
2012-07-10 18:02 ` Junio C Hamano
2012-07-11 14:14 ` Carlos Martín Nieto
2012-07-11 16:53 ` Junio C Hamano
2012-07-12 10:27 ` Carlos Martín Nieto
-- strict thread matches above, loose matches on Subject: below --
2012-08-20 13:47 [PATCH 0/3] Improve branch UI for setting upstream information Carlos Martín Nieto
2012-08-20 13:47 ` [PATCH 1/3] branch: introduce --set-upstream-to Carlos Martín Nieto
2012-08-30 17:23 [PATCHv2 0/3] Improve branch UI for setting upstream information Carlos Martín Nieto
2012-08-30 17:23 ` [PATCH 1/3] branch: introduce --set-upstream-to Carlos Martín Nieto
2012-08-30 17:51 ` Ralf Thielow
2012-08-31 15:22 ` Carlos Martín Nieto
2012-08-31 15:30 ` Ralf Thielow
2012-08-31 17:09 ` Junio C Hamano
2012-09-01 15:13 ` Carlos Martín Nieto
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=vpq394zo86k.fsf@bauges.imag.fr \
--to=matthieu.moy@grenoble-inp$(echo .)fr \
--cc=cmn@elego$(echo .)de \
--cc=git@vger$(echo .)kernel.org \
--cc=gitster@pobox$(echo .)com \
--cc=jrnieder@gmail$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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