Message ID | 20210514003104.94644-1-sandals@crustytoothpaste.net (mailing list archive) |
---|---|
Headers | show |
Series | Asciidoctor native manpage builds | expand |
brian m. carlson wrote: > @@ Documentation/asciidoctor-extensions.rb: module Git > elsif parent.document.basebackend? 'html' > %(<a href="#{prefix}#{target}.html">#{target}(#{attrs[1]})</a>) > + elsif parent.document.basebackend? 'manpage' > -+ %(\\fB#{target}\\fP\\fR(#{attrs[1]})\\fP) > ++ %(\e\\fB#{target}\e\\fP\e\\fR(#{attrs[1]})\e\\fP) > elsif parent.document.basebackend? 'docbook' > "<citerefentry>\n" \ > "<refentrytitle>#{target}</refentrytitle>" \ Huh? Didn't you say \e was not needed? You are doing basically the same thing thing my patches now, except in a more convoluted way.
On 2021-05-14 at 19:07:06, Felipe Contreras wrote: > brian m. carlson wrote: > > @@ Documentation/asciidoctor-extensions.rb: module Git > > elsif parent.document.basebackend? 'html' > > %(<a href="#{prefix}#{target}.html">#{target}(#{attrs[1]})</a>) > > + elsif parent.document.basebackend? 'manpage' > > -+ %(\\fB#{target}\\fP\\fR(#{attrs[1]})\\fP) > > ++ %(\e\\fB#{target}\e\\fP\e\\fR(#{attrs[1]})\e\\fP) > > elsif parent.document.basebackend? 'docbook' > > "<citerefentry>\n" \ > > "<refentrytitle>#{target}</refentrytitle>" \ > > Huh? Didn't you say \e was not needed? Yes, but I believe in that case my build was broken and I was incorrect. > You are doing basically the same thing thing my patches now, except in a > more convoluted way. The way your patches do it, if someone adds a line like this: _abc linkgit:git-update-index[1] def_ the latter part (def) is not italicized. In my version, it is, which is the correct behavior.
brian m. carlson wrote: > On 2021-05-14 at 19:07:06, Felipe Contreras wrote: > > brian m. carlson wrote: > > > @@ Documentation/asciidoctor-extensions.rb: module Git > > > elsif parent.document.basebackend? 'html' > > > %(<a href="#{prefix}#{target}.html">#{target}(#{attrs[1]})</a>) > > > + elsif parent.document.basebackend? 'manpage' > > > -+ %(\\fB#{target}\\fP\\fR(#{attrs[1]})\\fP) > > > ++ %(\e\\fB#{target}\e\\fP\e\\fR(#{attrs[1]})\e\\fP) > > > elsif parent.document.basebackend? 'docbook' > > > "<citerefentry>\n" \ > > > "<refentrytitle>#{target}</refentrytitle>" \ > > > > Huh? Didn't you say \e was not needed? > > Yes, but I believe in that case my build was broken and I was incorrect. I see. If it helps you I'm using this script [1] to run the specific version of asciidoctor of a git repository (their wrapper is wrong). > > You are doing basically the same thing thing my patches now, except in a > > more convoluted way. > > The way your patches do it, if someone adds a line like this: > > _abc linkgit:git-update-index[1] def_ > > the latter part (def) is not italicized. In my version, it is, which is > the correct behavior. Right, but my version is precisely what asciidoc+docbook generates in the simplest case. I agree your version is superior (although I wouldn't do the second \fR \fP). But that belongs in a separate patch IMO. Cheers. [1] https://dpaste.com/3AEDTFCSK