threads / patch / 44389

patchFix typo in 2.11.0 RelNotes

Subject: [PATCH] Fix typo in 2.11.0 RelNotes

## tl;dr

3 messages between Oct 28, 2016 and Oct 28, 2016. Diffs are folded; open one to read it.

replies: 2people: 2as markdown or json

Henrik Ahlgren· Oct 28, 2016, 10:47 UTC · lore
Signed-off-by: Henrik Ahlgren <pablo@seestieto.com>
---
 Documentation/RelNotes/2.11.0.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Show changes to Documentation/RelNotes/2.11.0.txt +1 −1
diff --git a/Documentation/RelNotes/2.11.0.txt b/Documentation/RelNotes/2.11.0.txt
index 3590620..1d3a07d 100644
--- a/Documentation/RelNotes/2.11.0.txt
+++ b/Documentation/RelNotes/2.11.0.txt
@@ -5,7 +5,7 @@ Backward compatibility notes.
 
  * An empty string used as a pathspec element has always meant
    'everything matches', but it is too easy to write a script that
-   finds a path to remove in $path and run 'git rm "$paht"', which
+   finds a path to remove in $path and run 'git rm "$path"', which
    ends up removing everything.  This release starts warning about the
    use of an empty string that is used for 'everything matches' and
    asks users to use a more explicit '.' for that instead.
-- 
2.1.4
Junio C Hamano· Oct 28, 2016, 13:03 UTC · re: Henrik Ahlgren · lore

Re: [PATCH] Fix typo in 2.11.0 RelNotes

Henrik Ahlgren <pablo@seestieto.com> writes:
Show 18 quoted lines
> Signed-off-by: Henrik Ahlgren <pablo@seestieto.com>
> ---
>  Documentation/RelNotes/2.11.0.txt | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/Documentation/RelNotes/2.11.0.txt b/Documentation/RelNotes/2.11.0.txt
> index 3590620..1d3a07d 100644
> --- a/Documentation/RelNotes/2.11.0.txt
> +++ b/Documentation/RelNotes/2.11.0.txt
> @@ -5,7 +5,7 @@ Backward compatibility notes.
>  
>   * An empty string used as a pathspec element has always meant
>     'everything matches', but it is too easy to write a script that
> -   finds a path to remove in $path and run 'git rm "$paht"', which
> +   finds a path to remove in $path and run 'git rm "$path"', which
>     ends up removing everything.  This release starts warning about the
>     use of an empty string that is used for 'everything matches' and
>     asks users to use a more explicit '.' for that instead.

What you spotted is certainly a typo, but it is a deliberate one that must not be fixed like this. "..., but it is too easy to ..." is illustrating a scenario in which an empty string is accidentally given to "git rm" as a pathspec by mistake, and the example it uses is for the user to prepare a path to be removed in variable $path, and referring to it as its typoed $paht by mistake. Fixing that typo in this paragraph defeats the whole point of the example.

But the fact that you spotted the typo (which is good; we want the deliberate typo in the example to be clearly visible) and thought that the writer of the paragraph must have meant a non-typoed version there (which is bad) indicates that the paragraph needs improvement to save readers from making the same mis-reading as you did.

If the original text were like the following, would it have been clear enough that prevented you from sending your patch?

 * An empty string used as a pathspec element has always meant
   'everything matches', but it is too easy to write a script that
   finds a path to remove in $path and run 'git rm "$paht"' by 
   mistake (when the user meant to give "$path"), which ends up
   removing everything.  This release starts warning about the
   use of an empty string that is used for 'everything matches' and
   asks users to use a more explicit '.' for that instead.
Thanks.
Henrik Ahlgren· Oct 28, 2016, 15:33 UTC · re: Junio C Hamano · lore

Re: [PATCH] Fix typo in 2.11.0 RelNotes

On Fri, 2016-10-28 at 06:03 -0700, Junio C Hamano wrote:
Show 10 quoted lines
> If the original text were like the following, would it have been
> clear enough that prevented you from sending your patch?
> 
>  * An empty string used as a pathspec element has always meant
>    'everything matches', but it is too easy to write a script that
>    finds a path to remove in $path and run 'git rm "$paht"' by 
>    mistake (when the user meant to give "$path"), which ends up
>    removing everything.  This release starts warning about the
>    use of an empty string that is used for 'everything matches' and
>    asks users to use a more explicit '.' for that instead.

Oops. Yes, but not sure if it really needs to be clear enough even for idiots like me. :-) Sorry.

← back to recent threads