Matt McCutchen's Web Site
/
rsync
/
rsync.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f964ac5
)
A perl script that does appropriate backslash escaping of '-' chars
author
Wayne Davison
<wayned@samba.org>
Tue, 24 Oct 2006 00:09:18 +0000
(
00:09
+0000)
committer
Wayne Davison
<wayned@samba.org>
Tue, 24 Oct 2006 00:09:18 +0000
(
00:09
+0000)
in manpages.
tweak_manpage
[new file with mode: 0755]
patch
|
blob
diff --git a/tweak_manpage
b/tweak_manpage
new file mode 100755
(executable)
index 0000000..
1efac26
--- /dev/null
+++ b/
tweak_manpage
@@ -0,0
+1,9
@@
+#!/usr/bin/perl -i -p
+s{(--\w[-\w]+)}{ $x = $1; $x =~ s/-/\\-/g; $x }eg;
+s/(?<!\\)-(['"\d*])/\\-$1/g;
+s/ -- / \\-\\- /g;
+s#(['"(= /,])-#$1\\-#g;
+s/(\\fB)-/$1\\-/g;
+s/(\[\w)-(\w\])/$1\\-$2/g;
+s{(\\f\(CW.*?\\fP)}{ $x = $1; $x =~ s/(?<!\\)-/\\-/g; $x }eg;
+s/(\.\w+)-/$1\\-/g;