Closed
Bug 730994
Opened 13 years ago
Closed 13 years ago
migration: Convert and normalize template calls in documents
Categories
(developer.mozilla.org Graveyard :: Editing, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: lorchard, Unassigned)
References
Details
(Whiteboard: c=wiki u=contributor p=2 t=2012-04-03)
During the migration process, template calls in MindTouch documents need to be converted and normalized for kumascript.
For the conversion part, template calls currently exist in MindTouch documents in HTML constructs of the following general form:
<span class="template">CSSXref('border')</span>
The new kumascript service expects syntax like the following:
{{ CSSXref('border') }}
For the normalization part, MindTouch accepts a few different ways to call a template:
MixedCaseName('parameter1', 'parameter2')
bug(689641)
template.lowercasename('border')
wiki.template('英語版章題', [ "Reusing tabs" ])
We need to parse each of these template call forms and normalize to something like this for kumascript:
{{ mixedcasename("parameter1", "parameter2") }}
{{ bug("689641") }}
{{ lowercasename("border") }}
{{ 英語版章題("Reusing tabs") }}
In other words:
* Squash mixed case variants of template names to all lower case. Alternatively, ensure kumascript accepts all case variants.
* Call templates just by name in macros. Normalize all variants of template.{name} and wiki.template("{name}"...) down to the simple kumascript macro syntax
* Watch for direct calls to mindtouch API methods and replace them, or at least make note of them as templates that needs to be written
Reporter | ||
Comment 1•13 years ago
|
||
Here's a gzipped, tab-delimited list of page name and template call extracted from all MindTouch pages:
https://bugzilla.mozilla.org/attachment.cgi?id=591545
That's useful to get a look at what the universe of template calls look like.
Blocks: 710728
Comment 2•13 years ago
|
||
Commit pushed to mdn at https://github.com/mozilla/kuma
https://github.com/mozilla/kuma/commit/3f599fb445acacc93f1b24c3511f30563d67e36f
Merge pull request #142 from lmorchard/bug-730994-migrate-macros
Bug 730994 migrate macros
Reporter | ||
Updated•13 years ago
|
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Updated•13 years ago
|
Whiteboard: c=wiki u=contributor p=2 t=2012-04-03
Assignee | ||
Updated•12 years ago
|
Version: MDN → unspecified
Assignee | ||
Updated•12 years ago
|
Component: Docs Platform → Editing
Updated•5 years ago
|
Product: developer.mozilla.org → developer.mozilla.org Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•