Minimize DTD sybsystem - #5742
Conversation
|
|
||
| <entity name="AuthenticationServices">Authentication Services</entity> | ||
|
|
||
| <entity name="CalendarandEventRelatedExtensions">Date and Time Related |
There was a problem hiding this comment.
some have gain a \n, is it intended ?
There was a problem hiding this comment.
It is intended, and it is ugly. There are a few lines that pass the 80 column marker. I'm considering removing the breaks, as this file is still (and forever will be?) small.
There was a problem hiding this comment.
I have purposely broken that rule in Acronyms.ent as well for the same reason. So I have absolutely no problem if this rule will be broken here.
|
The failures are expected, for now. The other PR on doc-base, that will be merged first, rename some doc-base/temp/ files and extensions. The only remaining DTD entity files left are doc-base/entities/global.ent and doc-lang/language-snippets.ent. The first one is to be simply erased after more changes are sent indo doc-base/configure.php, and the last one may linger for a while. After XML trim lands, all these |
| ]> | ||
|
|
||
| <set xmlns="http://docbook.org/ns/docbook" version="5.2" xml:id="index" xml:lang="&LANG;" xmlns:xlink="http://www.w3.org/1999/xlink"> | ||
| <set xml:id="index" xml:lang="" version="5.2" |
There was a problem hiding this comment.
Wouldn't it be better to hardcode "en" instead of leaving xml:lang empty?
There was a problem hiding this comment.
The ideia is to it always be filled, by API instead of by entity: https://github.com/php/doc-base/pull/336/files#diff-72f941dd66490c5d4d1315814f9ba8c7cd1329fce421907e5716156718527235R733
The code is in crude form, because I was to merge Trim PR first, then the other PR. But I delayed, I will change this line to consider $ret. &LANG; is still being generated so nothing breaks at first.
Hard coding with "en" may cause a future failure to be silently ignored.
There was a problem hiding this comment.
Also, note that --with-base-lang=extensions is creating Docbook files with root element marked as xml:lang=extensions", because the long standing convention of configure.php, where LANG means "language directory named with a valid BCP 47 language tag".
So, for example, doc-extensions/manual.xml can hard code xml:lang as "en", but the main manual leaves it empty, and the code only fills this attribute from LANG if it is currently empty.
|
Post tested, all languages build and validate. Let me know if there is some issue. Next in line is XML trim, userland XML assembler and a few more rounds of configure.php modernization, after a small vacation. XML trim, in particular, will take time, until I borrow a Windows machine to test it, or to learn enough about Windows images in docker or GH CI as a substitute. |
The
doc-enside of DTD subsystem minimization.Convert
language-defs.entinto XML, and rewritemanual.xmlto use the minimized DTD configuration. Also inmanual.xml:<set>namespaces is reorganized,&global.function-index;is not necessary anymore.This PR depends on the PR with the same name on the doc-base side.
Comments and reviews are welcome. Plan to merge this in one week.