[MediaWiki-l] composer installers: Behavior of type "mediawiki-*"

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[MediaWiki-l] composer installers: Behavior of type "mediawiki-*"

Robert Vogel
Hi!


I've stumbled over a strange implementation in the composer installer for MediaWiki related projects:


A package with the name "some-cool-extension" and type "mediawiki-extension" will be installed as "<mediawiki>/extensions/SomeCoolExtension". --> The name gets translated from "dashed-lowecase" into "UpperCamelCase" [1].


A package with the name "some-cool-skin" and type "mediawiki-skin" will be installed as "<mediawiki>/skins/some-cool". --> The "-skin" suffix is being removed, but no further transformation is being applied [2]. (Not even some uppercaseing. E.g. Vector skin circumvents this by the declaration of an "installer-name" [3]).


Does anybody know _why_ this difference is being made?


[1] https://github.com/composer/installers/blob/master/src/Composer/Installers/MediaWikiInstaller.php#L38

[2] https://github.com/composer/installers/blob/master/src/Composer/Installers/MediaWikiInstaller.php#L45

[3] https://github.com/wikimedia/mediawiki-skins-Vector/blob/master/composer.json#L34


--

Robert Vogel
_______________________________________________
MediaWiki-l mailing list
To unsubscribe, go to:
https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
Reply | Threaded
Open this post in threaded view
|

Re: composer installers: Behavior of type "mediawiki-*"

Stephan Gambke-3
Hi Robert.

That's because skins used to be stored in folders with lower-case names.
E.g. see https://github.com/wikimedia/mediawiki/tree/1.23.17/skins

Cheers
Stephan

> -------- Original Message --------
> Subject: [MediaWiki-l] composer installers: Behavior of type "mediawiki-*"
> Local Time: September 14, 2017 3:23 PM
> UTC Time: September 14, 2017 1:23 PM
> From: [hidden email]
> To: MediaWiki announcements and site admin list <[hidden email]>
>
> Hi!
>
> I"ve stumbled over a strange implementation in the composer installer for MediaWiki related projects:
>
> A package with the name "some-cool-extension" and type "mediawiki-extension" will be installed as "<mediawiki>/extensions/SomeCoolExtension". --> The name gets translated from "dashed-lowecase" into "UpperCamelCase" [1].
>
> A package with the name "some-cool-skin" and type "mediawiki-skin" will be installed as "<mediawiki>/skins/some-cool". --> The "-skin" suffix is being removed, but no further transformation is being applied [2]. (Not even some uppercaseing. E.g. Vector skin circumvents this by the declaration of an "installer-name" [3]).
>
> Does anybody know _why_ this difference is being made?
>
> [1] https://github.com/composer/installers/blob/master/src/Composer/Installers/MediaWikiInstaller.php#L38
>
> [2] https://github.com/composer/installers/blob/master/src/Composer/Installers/MediaWikiInstaller.php#L45
>
> [3] https://github.com/wikimedia/mediawiki-skins-Vector/blob/master/composer.json#L34
>
> --
>
> Robert Vogel
> _______________________________________________
> MediaWiki-l mailing list
> To unsubscribe, go to:
> https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
_______________________________________________
MediaWiki-l mailing list
To unsubscribe, go to:
https://lists.wikimedia.org/mailman/listinfo/mediawiki-l