Re: [PATCH 1/2] alternates: accept double-quoted paths
- From
Duy Nguyen <pclouds@gmail.com>
- Date
- Dec 13, 2016, 11:30 UTC
- Message-ID
- <CACsJy8B52ZDRTUjGLqub_1wELtugv99xbDnBg1PX1LUTb6nVMQ@mail.gmail.com>
- In-Reply-To
- <20161212195222.rxnabok6amklt2zf@sigill.intra.peff.net>
On Tue, Dec 13, 2016 at 2:52 AM, Jeff King <peff@peff.net> wrote:
Show 10 quoted lines
> Instead, let's treat names as unquoted unless they begin > with a double-quote, in which case they are interpreted via > our usual C-stylke quoting rules. This also breaks > backwards-compatibility, but in a smaller way: it only > matters if your file has a double-quote as the very _first_ > character in the path (whereas an escape character is a > problem anywhere in the path). It's also consistent with > many other parts of git, which accept either a bare pathname > or a double-quoted one, and the sender can choose to quote > or not as required.
At least attr has the same problem and is going the same direction [1]. Cool. (I actually thought the patch was in and evidence that this kind of backward compatibility breaking was ok, turns out the patch has stayed around for years)
[1] http://public-inbox.org/git/%3C20161110203428.30512-18-sbeller@google.com%3E/
-- Duy