Git development
 help / color / mirror / Atom feed
From: Petr Baudis <pasky@suse.cz>
To: Jari Aalto <jari.aalto@cante.net>
Cc: git@vger.kernel.org
Subject: Re: [RFC] Branch naming -- allowed characters?
Date: Sun, 26 Aug 2007 12:17:35 +0200	[thread overview]
Message-ID: <20070826101735.GI1219@pasky.or.cz> (raw)
In-Reply-To: <bqcuhe0c.fsf@cante.net>

On Sun, Aug 26, 2007 at 10:54:43AM CEST, Jari Aalto wrote:
> I just noticed this while trying to track quilt project and making a
> local branch with name '.pc':
> 
>     'fatal: '.pc' is not a valid branch name.'
> 
> Would it be possible to allow using arbitrary names with branches in
> future git, even UTF-8?
> 
> If that is not possible, would it be possible to at least broaden the
> charcter set with regular typeable US ascii letters, excluding the
> control ones. Something found in filenames/URLs. Like regexp:
> 
>     [][{}()_=+%!&@#~*.:;,/A-Za-z-]

I think UTF-8 might be possible, though I'd be careful because of legacy
systems (my main home system could be still considered "legacy", for
example; BTW, does Linux fbcon already support reasonable utf8 _and_
16*16 colors?). If legacy system cannot display commit message properly,
it's not that big deal and besides the message is usually still mostly
legible. If you cannot properly refer a branch because you live on a
legacy system, that makes for a showstopper.

About extending the allowed characters, one issue is caring whether we
and all the procelain make sure to quote branch name properly
everywhere. Hopefully so, but is anybode sure?

Bigger issue is that some of these characters have special meaning in
revids. For example ':' is special for Git, meaning "blob of given
filename in given tree". We want to keep some room for further grow and
possible added semantics. (For example, I still haven't completely given
up the idea of using dot-starting names for "autoprivate" refs. ;-)

Compared to this, the benefit of _allowing_ the special characters
doesn't seem to be very large and I can't really imagine many people
wanting to use = or + in their refnames.

> [*] Emacs even saves with names like: *Messages*

I'm sure vim can too. ;-)

-- 
				Petr "Pasky" Baudis
Ever try. Ever fail. No matter. // Try again. Fail again. Fail better.
		-- Samuel Beckett

      reply	other threads:[~2007-08-26 10:17 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-26  8:54 [RFC] Branch naming -- allowed characters? Jari Aalto
2007-08-26 10:17 ` Petr Baudis [this message]

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=20070826101735.GI1219@pasky.or.cz \
    --to=pasky@suse.cz \
    --cc=git@vger.kernel.org \
    --cc=jari.aalto@cante.net \
    /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