Thread (100 messages) 100 messages, 4 authors, 2018-04-28

Re: [PATCH v2 1/3] worktree: improve message when creating a new worktree

From: Thomas Gummerer <hidden>
Date: 2018-02-09 11:27:24

On 02/07, Eric Sunshine wrote:
On Sun, Feb 4, 2018 at 9:12 PM, Duy Nguyen [off-list ref] wrote:
quoted
As a former translator, I'm not thrilled to see a sentence broken into
two pieces like this. I'm not a Japanese translator, but I think this
sentence is translated differently when the translator sees the whole
line "Preparing ..., setting ...".

I think the purpose of "Preparing..." in the first place is to show
something when git is busy checkout out the worktree. As long as we
print it before git-reset, we should be good.
The original message was "Enter <worktree>" which had the potential to
confuse someone into thinking the working directory had changed[1], so
it was changed to "Preparing...". The reason for keeping that message
(rather than dropping it outright) was to provide context to messages
printed after it, especially messages such as "HEAD is now at..."
which might otherwise confuse the reader into thinking that HEAD in
the current worktree changed rather than HEAD in the new
worktree[2,3].
Thanks for the background!  In that light, since we're already
customizing the "HEAD is now at..." message, is it worth dropping the
message now, maybe using something like "Worktree HEAD is now at ...",
or something similar?

This would loose the information about the identifier of the worktree,
but from a coarse look at the man page it doesn't seem like we
advertise that widely (The only thing related to it I could find is

    If the last path components in the working tree's path is unique among
    working trees, it can be used to identify worktrees. For example if
    you only have two working trees, at "/abc/def/ghi" and "/abc/def/ggg",
    then "ghi" or "def/ghi" is enough to point to the former working tree.

for which we don't need to print the identifier anywhere.  We don't
seem to mention the case where the last part is unique, and we add a
number to make the identifier unique.

So given that maybe it would even be better to hide the part about the
identifier, as it seems more like an implementation detail than
relevant to the end user?
[1]: https://public-inbox.org/git/55A8F4B1.9060304@drmicha.warpmail.net/
[2]: https://public-inbox.org/git/CAPig+cRSHwmmF9cCUbRrDCCW4kvg9PeOUxP5VQpSGfxzMxHWOQ@mail.gmail.com/
[3]: https://public-inbox.org/git/CAPig+cSLs4-uKicVMBSKnEro_FYD722Hs1_U6qzTriM8Ciok2Q@mail.gmail.com/
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help