Page MenuHomePhabricator

Update {{Extension}} to accept compatibility policy = lts
Closed, ResolvedPublic

Description

@sbassett The template allows only for values rel or master in the compatibility policy field. I only support LTS release branches. Usually I remove all other branched. Might have forgotten that, so thanks for cherry-picking to the other branches, @Jdforrester-WMF , but I'll probably remove these in the near future.

https://www.mediawiki.org/wiki/Template:Extension

Event Timeline

Reedy created this task.Dec 20 2019, 2:44 PM
Restricted Application added subscribers: Liuxinyu970226, Aklapper. · View Herald TranscriptDec 20 2019, 2:44 PM
Reedy added a comment.Dec 20 2019, 2:46 PM

Translate syntax in the template... Therefore here be dragons...

{{#if:{{{compatibility policy|}}}|
<tr>
<td>{{ll|Compatibility#mediawiki_extensions|'''<translate><!--T:43--> Compatibility policy</translate>'''}}</td>
<td>{{#switch:{{{compatibility policy}}}<!--
      -->|master=<translate><!--T:44--> master</translate><!--
      -->|rel=<translate><!--T:45--> release branches</translate><!--
      -->|#default=<span class="error"><translate><!--T:47--> invalid</translate></span>{{#ifeq:{{{templatemode|<noinclude>nocats</noinclude>}}}|nocats|<!-- do nothing -->|<!--else-->{{#if:{{#translation:}}||[[Category:Extensions without a compatibility policy]]}}}}<!--
      -->}}</td>
</tr>
|{{#ifeq:{{{templatemode|<noinclude>nocats</noinclude>}}}|nocats|<!-- do nothing -->|<!--else-->{{#if:{{#translation:}}||[[Category:Extensions without a compatibility policy]]}}}}
}}
sbassett added a comment.EditedDec 20 2019, 2:53 PM

Guessing it's more complex than just adding something like: -->|ltsrel=<translate><!--T:46--> lts release branches</translate><!--

Reedy added a comment.Dec 20 2019, 3:30 PM

Guessing it's more complex than just adding something like: -->|ltsrel=<translate><!--T:46--> lts release branches</translate><!--

T:46 is already used, but in theory, you just need to find the first next free number... Looks like it has circa 190 units

Guessing it's more complex than just adding something like: -->|ltsrel=<translate><!--T:46--> lts release branches</translate><!--

T:46 is already used, but in theory, you just need to find the first next free number... Looks like it has circa 190 units

Translation unit numbers shouldn't be added by hand (or at least that's what I have been told), unless you want to manually fix them by moving them around or restoring a unit that was previously deleted. The system autogenerates those magic HTML comments when the page/template is marked for translation. Otherwise you may end reusing a deleted unit that had a completely unrelated translation, accidental duplicate units, etc.