From 9a96e0a19866bb59d6dd7dfb4bf1fc11bc63b16f Mon Sep 17 00:00:00 2001 From: "G. Branden Robinson" Date: Sun, 5 Nov 2023 13:59:48 -0600 Subject: [PATCH] Fix *roff string usage nit String definitions were being used with a pointless leading double quote. This syntax is used only to define strings containing leading space characters. (You might also use it defensively if you're defining one string whose contents start with the interpolation of another, and the latter might interpolate leading space--but that is not the case here.) Remove unnecessary leading quotes from string definitions. * doc/Guidebook.mn: Do it. Also annotate empty strings with comment. * sys/unix/hints/include/gbdates-post.370: Don't put them back. https://www.gnu.org/software/groff/manual/groff.html.node/Strings.html --- doc/Guidebook.mn | 14 +++++++------- sys/unix/hints/include/gbdates-post.370 | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/doc/Guidebook.mn b/doc/Guidebook.mn index 707471f8a..2f3479999 100644 --- a/doc/Guidebook.mn +++ b/doc/Guidebook.mn @@ -33,14 +33,14 @@ .if n .do ftr CR R \" if formatting for a terminal, substitute R for CR . \" (the substitution affects both '\f' and '.ft') . -.ds h0 "NetHack Guidebook -.ds h1 +.ds h0 NetHack Guidebook +.ds h1 \" empty .ds h2 % -.ds vr "NetHack 3.7.0 -.ds f0 "\*(vr -.ds f1 -.\"DO NOT REMOVE NH_DATESUB .ds f2 "DATE(%B %-d, %Y) -.ds f2 "November 6, 2023 +.ds vr NetHack 3.7.0 +.ds f0 \*(vr +.ds f1 \" empty +.\"DO NOT REMOVE NH_DATESUB .ds f2 DATE(%B %-d, %Y) +.ds f2 November 6, 2023 . .\" A note on some special characters: .\" \(lq = left double quote diff --git a/sys/unix/hints/include/gbdates-post.370 b/sys/unix/hints/include/gbdates-post.370 index a736e30f9..9809a6df9 100755 --- a/sys/unix/hints/include/gbdates-post.370 +++ b/sys/unix/hints/include/gbdates-post.370 @@ -2,7 +2,7 @@ ifdef MAKEFILE_DOC ifdef GB_DATESTAMP Guidebook.dated.mn: $(GUIDEBOOK_MN_SRC) - @awk 'f{$$0=".ds f2 \"$(GB_DATESTAMP)";f=0}/NH_DATESUB/{f=1} 1' < $(GUIDEBOOK_MN_SRC) > $@ + @awk 'f{$$0=".ds f2 $(GB_DATESTAMP)";f=0}/NH_DATESUB/{f=1} 1' < $(GUIDEBOOK_MN_SRC) > $@ Guidebook.dated.tex: $(GUIDEBOOK_TEX_SRC) @awk 'f{$$0="\\date{$(GB_DATESTAMP)}";f=0}/NH_DATESUB/{f=1} 1' < $(GUIDEBOOK_TEX_SRC) > $@ endif # GB_DATESTAMP