<table><tr><td style="">turbov added a comment.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D7175" rel="noreferrer">View Revision</a></tr></table><br /><div><div><blockquote style="border-left: 3px solid #8C98B8;
color: #6B748C;
font-style: italic;
margin: 4px 0 12px 0;
padding: 8px 12px;
background-color: #F8F9FC;">
<div style="font-style: normal;
padding-bottom: 4px;">In <a href="https://phabricator.kde.org/D7175#133152" style="background-color: #e7e7e7;
border-color: #e7e7e7;
border-radius: 3px;
padding: 0 4px;
font-weight: bold;
color: black;text-decoration: none;" rel="noreferrer">D7175#133152</a>, <a href="https://phabricator.kde.org/p/dhaumann/" style="
border-color: #f1f7ff;
color: #19558d;
background-color: #f1f7ff;
border: 1px solid transparent;
border-radius: 3px;
font-weight: bold;
padding: 0 4px;" rel="noreferrer">@dhaumann</a> wrote:</div>
<div style="margin: 0;
padding: 0;
border: 0;
color: rgb(107, 116, 140);"><p>I see seveal issues that imo should be addressed:</p>
<ol class="remarkup-list">
<li class="remarkup-list-item">Please add a test case in autotest/input/ or extend it if one already exists (did you run make test?)</li>
</ol></div>
</blockquote>
<p>no, I don't run tests yet (it is too complicated to build the repo for me nowadays)</p>
<blockquote style="border-left: 3px solid #a7b5bf; color: #464c5c; font-style: italic; margin: 4px 0 12px 0; padding: 4px 12px; background-color: #f8f9fc;">
<ol class="remarkup-list" start="2">
<li class="remarkup-list-item">How does it work, are we supposed to run this command from time to time manually? If so, then I'd be ok with that.</li>
</ol></blockquote>
<p>it work pretty simple:</p>
<ol class="remarkup-list">
<li class="remarkup-list-item">reading YAML (as a Python's <tt style="background: #ebebeb; font-size: 13px;">dict</tt>)</li>
<li class="remarkup-list-item">prepare (rename keys, & etc) data for renderer</li>
<li class="remarkup-list-item">render data (a <tt style="background: #ebebeb; font-size: 13px;">dict</tt>) into the Jinja template</li>
</ol>
<p>as I said the previous generator became unstable -- parsing the output of <tt style="background: #ebebeb; font-size: 13px;">cmake --help</tt> is not reliable, so this generator uses "static" YAML file, which should be updated manually</p>
<blockquote style="border-left: 3px solid #a7b5bf; color: #464c5c; font-style: italic; margin: 4px 0 12px 0; padding: 4px 12px; background-color: #f8f9fc;">
<ol class="remarkup-list" start="3">
<li class="remarkup-list-item">How high is the maintenance burden over time: I understand that this should this, but given we have a yaml file that needs to be maintained manually, I wonder whether we simply move the maintenance from one place to another and additionally introduce complexity (in terms of additional tooling) one first needs to understand before being able to fix things.</li>
</ol></blockquote>
<p>the point w/ the current generator: I'm far from sure it "parse" everything correct... moreover, I know exactly that it "parses" <tt style="background: #ebebeb; font-size: 13px;">cmake --help</tt> output incorrectly (and one have to fix the generated syntax manually after the generator) and there is really hard to make the generator right cuz the informal/irregular nature of help screens.<br />
in contrast, the new approach offers a full control over the generated syntax, yeah, by the cost of "manual" maintenance of the YAML file (I tried to make it as simple as possible, and I'm sure it shouldn't be a problem to anyone to add anything to it %)<br />
Usually, I read CMake's ChangeLog carefully after any new release, spotting new commands/variables/properties/etc and this is the time to update syntax (YAML file)...</p>
<blockquote style="border-left: 3px solid #a7b5bf; color: #464c5c; font-style: italic; margin: 4px 0 12px 0; padding: 4px 12px; background-color: #f8f9fc;">
<ol class="remarkup-list" start="4">
<li class="remarkup-list-item">The kateversion is back to 2.4 and hard-coded colors are used again. Previously, it was set to 5.0, and used already the newly introduced default styles. I strongly suggest to keep the new default styles - we purposefully changed this some time ago, and I dislike that fact that we go a step back here.</li>
</ol></blockquote>
<p>previous cmake.xml do not use anything from modern kate, this syntax works fine w/ KDE4 version of kate. <br />
anyway, it would be easy to fix it and remove hardcoded colors anyway...</p>
<p>the hardest part is to realize would this approach be accepted or not</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R216 Syntax Highlighting</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D7175" rel="noreferrer">https://phabricator.kde.org/D7175</a></div></div><br /><div><strong>To: </strong>turbov, dhaumann, Kate, Framework: Syntax Hightlighting, vkrause<br /><strong>Cc: </strong>cullmann, Frameworks<br /></div>