git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Kenneth Cochran <kenneth.cochran101@gmail.com>
Cc: git@vger.kernel.org, Sahil Dua <sahildua2305@gmail.com>,
	Duy Nguyen <pclouds@gmail.com>, Jeff King <peff@peff.net>
Subject: Re: [RFC PATCH 0/4] Add alias option to git branch
Date: Tue, 05 Mar 2019 22:21:12 +0900	[thread overview]
Message-ID: <xmqqa7i9v4mv.fsf@gitster-ct.c.googlers.com> (raw)
In-Reply-To: <47CA9077-E8C1-4093-8B36-2D5D3DE2D886@gmail.com> (Kenneth Cochran's message of "Mon, 4 Mar 2019 09:45:45 -0600")

Kenneth Cochran <kenneth.cochran101@gmail.com> writes:

> From c1bad54b29ae1c1d8548d248f6ecaa5959e55f7b Mon Sep 17 00:00:00 2001
> From: Kenneth Cochran <kenneth.cochran101@gmail.com>
> Date: Mon, 4 Mar 2019 09:40:22 -0600
> Subject: [RFC PATCH 0/4] Add alias option to git branch
> Cc: Sahil Dua <sahildua2305@gmail.com>,
>     Duy Nguyen <pclouds@gmail.com>,
>     Jeff King <peff@peff.net>

Avoid using these in-body headers.

Reader's MUA won't show this "Subject:", but instead show the same
"Add alias option to gir branch", among hundreds of mailing list
messages, making it very tempting to ignore these four messages.


> I find myself often using git symbolic-ref to get around work requirements to use branch names that are not very human friendly.
> There are a few problems with this:
> 	- There’s a lot of text to type
> 	- Mistyping certain parts (heads/refs) will do things other than create a branch alias
> 	- It will happily overwrite an existing branch
> 	- Deleting one that is checked out will put HEAD in an invalid state.

Meh.

All of the above are problems _you_ create by trying to use symbolic
refs.  If the project wants to use an overlong branch name, using it
with "git branch" or "git checkout" or whatever would be a much
better solution.  Command-line completion will complete long branch
names, and "git branch overly-long-name-of-an-existing-branch" will
not overwrite an existing branch (without --force).  "git branch -d
overly-long-name-of-an-existing-branch" would not delete an
checked-out branch, either.


  parent reply	other threads:[~2019-03-05 13:21 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-04 15:45 [RFC PATCH 0/4] Add alias option to git branch Kenneth Cochran
2019-03-04 15:47 ` [RFC PATCH 1/4] " Kenneth Cochran
2019-03-04 15:48   ` [RFC PATCH 2/4] " Kenneth Cochran
2019-03-04 15:49     ` [RFC PATCH 3/4] " Kenneth Cochran
2019-03-04 15:49       ` [RFC PATCH 4/4] " Kenneth Cochran
2019-03-04 16:38         ` Kenneth Cochran
     [not found]         ` <CAJ145vUChd7+5QkmJsOK3bzZsudWfzZYp5wHZDzoq8SKSv0g0A@mail.gmail.com>
2019-03-04 19:33           ` Phil Sainty
2019-03-04 19:52             ` Kenneth Cochran
2019-03-05 13:21 ` Junio C Hamano [this message]
2019-03-05 17:36   ` [RFC PATCH 0/4] " Kenneth Cochran
2019-03-06 10:13     ` Phil Sainty

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=xmqqa7i9v4mv.fsf@gitster-ct.c.googlers.com \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=kenneth.cochran101@gmail.com \
    --cc=pclouds@gmail.com \
    --cc=peff@peff.net \
    --cc=sahildua2305@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).