git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Duy Nguyen <pclouds@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Nathan Collins <nathan.collins@gmail.com>, git <git@vger.kernel.org>
Subject: Re: [BUG?] Spaces not allowed in directory names in .git/info/attributes
Date: Tue, 24 May 2016 08:37:33 +0700	[thread overview]
Message-ID: <CACsJy8DXW-K-iNO65yuzMLPZS_8+R1gsQgNftwei1XUZNxhicg@mail.gmail.com> (raw)
In-Reply-To: <xmqqmvng8qle.fsf@gitster.mtv.corp.google.com>

On Tue, May 24, 2016 at 3:30 AM, Junio C Hamano <gitster@pobox.com> wrote:
> Nathan Collins <nathan.collins@gmail.com> writes:
>
>> Example session:
>>
>>     $ git init test.git
>>     Initialized empty Git repository in /tmp/test.git/.git/
>>     $ cd test.git
>>     $ mkdir "dir name"
>>     $ touch dir\ name/file.txt
>>     $ echo "dir\\ name/file.txt -text -whitespace" >> .git/info/attributes
>>     $ git add dir\ name/file.txt
>>     name/file.txt is not a valid attribute name: .git/info/attributes:1
>
> That's because spaces are not allowed in paths there.
>
>         echo "dir?name/file.txt -text" >.git/info/attributes
>
> may be an easy workaround for now.

Maybe bring back [1] (cquoting paths) and optionally optionally with
backslash escaping? The conclusion at the end of that thread seems to
be "ok, we may break rare setups, we just need to be upfront about
it". Another option is the pathspec way: match quotes literally as
well.

[1] http://thread.gmane.org/gmane.comp.version-control.git/160597/focus=160720
-- 
Duy

  reply	other threads:[~2016-05-24  1:38 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-23 19:06 [BUG?] Spaces not allowed in directory names in .git/info/attributes Nathan Collins
2016-05-23 20:30 ` Junio C Hamano
2016-05-24  1:37   ` Duy Nguyen [this message]
2016-05-24 22:54     ` Junio C Hamano
2016-05-25 21:56     ` Junio C Hamano
2016-05-24 23:30   ` Nathan Collins

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

  List information: http://vger.kernel.org/majordomo-info.html

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

  git send-email \
    --in-reply-to=CACsJy8DXW-K-iNO65yuzMLPZS_8+R1gsQgNftwei1XUZNxhicg@mail.gmail.com \
    --to=pclouds@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=nathan.collins@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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).