diff options
author | G. Branden Robinson <g.branden.robinson@gmail.com> | 2018-11-12 12:02:31 -0500 |
---|---|---|
committer | G. Branden Robinson <g.branden.robinson@gmail.com> | 2018-11-12 12:42:38 -0500 |
commit | ea32b7d0462813fc3e7c423efb6d805273df9edd (patch) | |
tree | a8982a28e2bd9248c4044cf415473fb56ee2980a /makevarescape.sed | |
parent | b232e3b90e82b32e795793d78f12c6484b0870a7 (diff) | |
download | groff-git-ea32b7d0462813fc3e7c423efb6d805273df9edd.tar.gz |
makevarescape.sed: Add breakpoints, spaces, and ".
* makevarescape.sed:
+ Escape plain spaces and double-quotes (ASCII 32 and 34) so
that bad things don't happen if they are embedded in a Make
variable expanded in a man page @THUS@ _and_ given as an
argument to a macro that distinguishes its parameters, such
as .IR.
+ Add discretionary breaks after groups of slashes not
preceded by a space; e.g., transform "/usr/bin/groff" into
"/usr/\:bin/\:groff". Will also work on URLs
("https://\:example.com/\:page.html") in case we need that.
Signed-off-by: G. Branden Robinson <g.branden.robinson@gmail.com>
Diffstat (limited to 'makevarescape.sed')
-rw-r--r-- | makevarescape.sed | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/makevarescape.sed b/makevarescape.sed index 54f551300..8ece3e88f 100644 --- a/makevarescape.sed +++ b/makevarescape.sed @@ -1,6 +1,9 @@ s/\\/\\\\e/g +s/ /\\\\ /g +s/"/\\\\(dq/g s/'/\\\\(aq/g s/-/\\\\&/g s/\^/\\\\(ha/g s/`/\\\\(ga/g s/~/\\\\(ti/g +s|[^ ]/\+|&\\\\:|g |