File: 0014-Documentation-quoting-trouble-in-git-rm-discussion.diff

package info (click to toggle)
git 1%3A1.7.2.5-3
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 18,036 kB
  • ctags: 13,298
  • sloc: ansic: 108,217; sh: 74,973; perl: 23,370; tcl: 20,137; python: 3,843; makefile: 2,885; lisp: 1,779; asm: 98
file content (64 lines) | stat: -rw-r--r-- 2,305 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
From 0ec09226d61270761aae502c92e10b50b917090c Mon Sep 17 00:00:00 2001
From: Jonathan Nieder <jrnieder@gmail.com>
Date: Fri, 20 Aug 2010 05:21:53 -0500
Subject: Documentation: quoting trouble in "git rm" discussion
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

The current output (with Asciidoc 8.5.2) seems a bit broken:

	given two directories ‘d` and d2, there is a difference
	between using git rm 'd*’ and ‘git rm 'd/\*\’`, as the
	former will also remove all of directory d2.

In other words, the markup parses as

	given two directories << d` and _d2_, there is a difference
	between using _git rm 'd* >>_ and << git rm 'd/\*\ >> `.

I suspect there is an asciidoc bug involved (why is ' a candidate
closing-quote mark when it is preceded by a backslash?) but with
all the meanings of ` and ' involved I do not want to track it
down.  Better to use unambiguous {asterisk} and {apostrophe}
entities.

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
(cherry picked from commit 438ded457b6e0d1e615edd593faeeafdc8818fea)

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
---
 Documentation/asciidoc.conf |    1 +
 Documentation/git-rm.txt    |    3 ++-
 2 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/Documentation/asciidoc.conf b/Documentation/asciidoc.conf
index 87a90f2..6be8ba3 100644
--- a/Documentation/asciidoc.conf
+++ b/Documentation/asciidoc.conf
@@ -17,6 +17,7 @@ caret=&#94;
 startsb=&#91;
 endsb=&#93;
 tilde=&#126;
+apostrophe=&#39;
 backtick=&#96;
 
 ifdef::backend-docbook[]
diff --git a/Documentation/git-rm.txt b/Documentation/git-rm.txt
index c21d19e..d146751 100644
--- a/Documentation/git-rm.txt
+++ b/Documentation/git-rm.txt
@@ -78,7 +78,8 @@ a file that you have not told git about does not remove that file.
 
 File globbing matches across directory boundaries.  Thus, given
 two directories `d` and `d2`, there is a difference between
-using `git rm \'d\*\'` and `git rm \'d/\*\'`, as the former will
+using `git rm {apostrophe}d{asterisk}{apostrophe}` and
+`git rm {apostrophe}d/{asterisk}{apostrophe}`, as the former will
 also remove all of directory `d2`.
 
 REMOVING FILES THAT HAVE DISAPPEARED FROM THE FILESYSTEM
-- 
1.7.2.3.557.gab647.dirty