Hi David, On Mon, 4 Jun 2018, David Malcolm wrote: > Caveat/confession: I've never managed to successfully build MetaHTML, > so I've never run it.
yes, it's become increasingly difficult to build given how it's been abandoned unfortunately (which is something I had brought up with RMS even twice or so). Hence increasingly a bit of a burning platform to move away from. > Here's an attempt at porting the website from MetaHTML to a Python 3 > script. This is great! Thank you for doing this. > I've tested it lightly so far by comparing it to reference pages from > the built site (index.html, c99status.html, and install/test.html so > far). Can you also give something like gcc-8/*.html a try? In between those you pointed out and these I feel pretty comfortable about us having good coverage. > Does this look like the right idea? (it's not quite perfect yet, but > is pretty close for the pages I tested on). It's more procedural, when in principle declarative is nicer, *but* clearly something that works for everyone (who has Python) and is maintainable is a big step forward. And, heck, I may get to learn a bit of Python on the way. ;-) > Are there any other pages which have their own uses of MetaHTML that > I didn't spot yet? I cannot think of any; not with some of my recent (and not so recent) changes to push things to CSS and otherwise. > For now, I've attempted to faithfully reproduce the strange whitespace that > MetaHTML introduces, to make it easier to compare diffs. A followup would > be to remove that, to give more natural whitespace (thus keeping the > whitespace changes separated from non-whitespace changes, as it were). What do you think of simplifying this such that `diff -w -B` aka `diff --ignore-all-space --ignore-blank-lines` doesn't flag anything? That would be a way towards more natural whitespace as you refer to, and from my parsing of the Python code would make things a bit easier? Two small questions: given the main script is bin/preprocess, would it be okay to call the new one bin/preprocess-html-file instead of bin/process-html-file.py ? And possibly omit the .py to "hide" this implementation detail? Last weekend I started to think how to move nearly everything to HTML 5 (and as you may have seen started to patch in that direction) and devise a way to handle that in the framework with minimal effort. However, now that you have gone to the effort of creating this script, I am wondering whether we should simply do a flag day and switch to your script as quickly as possible, even before that transition is complete. What do you think? Gerald (on business travel last week and most of the next two, but trying to keep up by e-mail).