]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
gen: do italics/bold for a range of letters, not just single word
authorDaniel Stenberg <daniel@haxx.se>
Sat, 13 Jan 2024 09:49:20 +0000 (10:49 +0100)
committerDaniel Stenberg <daniel@haxx.se>
Sat, 13 Jan 2024 15:25:20 +0000 (16:25 +0100)
Previously it would match only on a sequence of non-space, which made it
miss to highlight for example "public suffix list".

Updated the recent cookie.d edit from 5da57193b732 to use bold instead
of italics.

Closes #12689

docs/cmdline-opts/cookie.d
docs/cmdline-opts/gen.pl

index 601a1958c80a3d570c6ab415c2359b4d0ef1c20f..108846c062b9f90b9ce32cabe28d0bd1ee68219c 100644 (file)
@@ -45,7 +45,7 @@ Users often want to both read cookies from a file and write updated cookies
 back to a file, so using both --cookie and --cookie-jar in the same command
 line is common.
 
-If curl is built with PSL (*Public Suffix List*) support, it detects and
+If curl is built with PSL (**Public Suffix List**) support, it detects and
 discards cookies that are specified for such suffix domains that should not be
 allowed to have cookies. If curl is *not* built with PSL support, it has no
 ability to stop super cookies.
index fbe0f546b882b187ba9670abd24a49e5ac79281d..b31a42b580fa03f5f98e32a16aa82d9989bf64ee 100755 (executable)
@@ -98,9 +98,9 @@ sub printdesc {
         }
         if($d !~ /^.\\"/) {
             # **bold**
-            $d =~ s/\*\*([^ ]*)\*\*/\\fB$1\\fP/g;
+            $d =~ s/\*\*(.*?)\*\*/\\fB$1\\fP/g;
             # *italics*
-            $d =~ s/\*([^ ]*)\*/\\fI$1\\fP/g;
+            $d =~ s/\*(.*?)\*/\\fI$1\\fP/g;
         }
         if(!$exam && ($d =~ /^ /)) {
             # start of example