Modules Mediawiki d'extension de langues
Les modules MediaWiki d'extension de langues (MLEB) sont un ensemble maintenu d'extensions Mediawiki offrant des fonctionnalités multilingues. Il essaie de fournir un moyen facile d'apporter un support de langue complet à un MediaWiki.
Aperçu des extensions
La version actuelle de MLEB contient six extensions :
MLEB est diffusé sur une base trimestrielle, ce qui vous permet de rester facilement à la pointe avec le support de langue en amélioration constante. Le paquet est testé avec les versions de MediaWiki diffusées récemment, afin de vous éviter la plupart des ruptures occasionnelles qui pourraient apparaître si vous utilisiez les dernières versions de développement de chaque extension.
Motivation
Le sélecteur universel de langue est un élément que vous devez avoir, car il fournit une fonctionnalité essentielle à tout utilisateur indépendamment du nombre de langues qu'il parle : la séléection de langue, la prise en charge des fontes pour l'affichage des écritures mal prises en charge par les systèmes d'exploitation communs, et les méthodes de saisie pour les langues typées qui n'utilisent pas l'alphabet latin. Il contient des fontes sous licence libre, qui couvrent la plupart les langues principales d'Amérique, d'Europe, du Moyen Orient, d'Inde et de l'Asie du Sud.
Maintenir du contenu multilingue dans un wiki est un véritable enfer si vous n'utilisez pas l'extension Translate , qui est utilisée par la Fondation Wikimedia, KDE, translatewiki.net et autres sites. Avec Localisation Update vos utilisateurs auront toujours les dernières traductions directement sorties du four. L'extension Clean Changes conserve la page de vos modifications récentes séparée de l'activité de traduction et d'autres filtrages.
Ne laissez pas passer votre chance de mettre en oeuvre vos talents linguistiques élémentaires : utilisez l'extension Babel pour marquer les langues que vous parlez et trouver d'autes locuteurs de la même langue sur votre wiki. Et, pour terminer l'extension cldr est une base de données de traduction de langues et de pays.
Notes de version et téléchargement
Latest release
- 2020.10: https://translatewiki.net/mleb/MediaWikiLanguageExtensionBundle-2020.10.tar.bz2
- sha256sum: 8a0b0282e3a1ef88b231f8c1fd8c922052eba6e0b55b75f87de940632f3730e1 [1]
- Announcement and Release Notes
- Compatible with MediaWiki 1.34 and above and requires PHP 7.2 or above.
- The Translate extension now requires MediaWiki 1.34 or above.
- Update the language selector on the Special:PageTranslation (Gerrit change 616762)
- Do not list all pages on marking a page for translation (Gerrit change 621034)
- Add API to fetch translation statistics (Gerrit change 623169)
- Replace PHPlot with Chart.js on Special:TranslationStats (tâche T134634)
- Fix mandatory deletion of sub pages when deleting translatable pages (Gerrit change 636871)
- Rename MessageValidator namespace to Validation (Gerrit change 616069)
- Legacy editor: remove various translation helpers, custom buttons
- Make Language stats appear better on mobile screens and make the header sticky (Gerrit change 631979)
- Tag untranslated translations units with lang and dir attributes (tâche T254484)
- Add magic word:
{{TRANSLATIONLANGUAGE}}
for translatable pages (tâche T254486) - Avoid showing bdi tags on Special:Translate (tâche T117852)
- Add Developer guide for Translate (tâche T256873)
- Fix "Translation page does not contain the latest translations/last translation" (tâche T255334)
- Fix "This namespace is reserved for content page translations" when trying to translate a recently created translation unit" (tâche T221119)
- ULS now defines unsupported skins (tâche T237036, tâche T235712)
- Remove configuration variables:
ULSCompactLinksForNewAccounts
andULSCompactLinksEnableAnon
(Gerrit change 632721)
Previous releases
- 2020.07: https://translatewiki.net/mleb/MediaWikiLanguageExtensionBundle-2020.07.tar.bz2
- sha256sum: 7334f6c0f4e00a451d976c81024c955061cffc3466d8a03fd223733992d0a2d5 [1]
- Announcement and Release Notes
- Compatible with MediaWiki 1.33 and above and requires PHP 7.2 or above.
- Update to cldr 37.
- Fixes to moving and deletion of translatable pages. (Phab:T168591)
- Display a help message when editing a translatable page source. (Phab:T192052)
- Translations are now published instead of saved, for consistency with rest of MediaWiki. (Phab:T131132)
- 2020.04: https://translatewiki.net/mleb/MediaWikiLanguageExtensionBundle-2020.04.tar.bz2
- sha256sum: 97dbf8846c62cbafa43b7b5f359c3fb55039846277ebb55dd7b00e42d356d709 [1]
- Announcement and Release Notes
- Compatible with MediaWiki 1.33 and above and requires PHP 7.2 or above.
- Remove PHP based entry point for Translate extension. Use
wfLoadExtension( 'Translate' );
to load the Translate extension. - Test and add support for PHP 7.4. Now all versions of PHP 7.2 and above are supported.
- SECURITY FIX: Translate: HTML from messages was not escaped in Special:ManageMessageGroups. If you do not use this page (e.g. only use translatable wiki pages) you are not affected. (Phab:T242115)
- 2020.01: https://translatewiki.net/mleb/MediaWikiLanguageExtensionBundle-2020.01.tar.bz2
- sha256sum: 94c6bb79e6b3bc55b8ca629165256a96da8dbd196999da09ba45a7e11cc7c194 [1]
- Announcement and Release Notes
- Compatible with MediaWiki 1.33 and above and requires PHP 7.2 or above.
- Updated to cldr 36.
- Prevent duplicate translation unit error from showing twice. (Phab:T236153)
- Add secondary check before displaying tpt-unknown-page error. (Phab:T221119)
- Display an error message if translation aids fail to load. (Phab:T221119)
- Improve message group selector performance reducing Translate API request time. (Phab:T236904)
- Update setlang to display confirmation dialog to change language. (Phab:T63115)
- 2019.10: https://translatewiki.net/mleb/MediaWikiLanguageExtensionBundle-2019.10.tar.bz2
- sha256sum: b7d6afdb365c7333829ab5b4e286c2f28e3a5f6f48d1584c1f43439e74a60de6 [1]
- Announcement and Release Notes
- Compatible with MediaWiki 1.32 and above and requires PHP 7.1.0 or above.
- PHP entry point has been deprecated. To load the Translate extension, please use the following,
wfLoadExtension( 'Translate' );
- Removed deprecated and unmaintained SolrTTMServer. Recommendation is to migrate to ElasticSearch. (Phab:T87985)
- Dropped support for HHVM.
- 2019.07: https://translatewiki.net/mleb/MediaWikiLanguageExtensionBundle-2019.07.tar.bz2
- sha256sum: 84cb6de241f62c7e5e9853d74390c4ffbf55cf35aab930c36f9ec5733a351130 [1]
- Announcement and Release Notes
- Compatible with MediaWiki 1.32 and above and requires PHP 7.0.0 or above.
- Update to cldr 35.1 (T220906).
- Translate and UniversalLanguageSelector now requires MediaWiki >= 1.32.0. Please upgrade!
- Added a new MessageValidator framework to improve translation validation. (T204568) (See documentation).
- Fixed invalid more warnings label shown during message translation (T220789)
- Added several African keyboards in UniversalLanguageSelector.
- 2019.04: https://translatewiki.net/mleb/MediaWikiLanguageExtensionBundle-2019.04.tar.bz2
- sha256sum: 5fbbd39acd1cc0e1edbd542a390daf1992d1526134ceb69248cdb4dced58f3a9 [1]
- Announcement and Release Notes
- Compatible with MediaWiki 1.31, 1.32 and above and requires PHP 7.0.0 or above.
- PHP entry point has been removed for CleanChanges and cldr. Warning will be displayed for deprecated PHP entry point. (T140007)
- Fixed fatal error on PageContentLanguage hook subscriber (T214358)
- Fixed broken Special:PageMigration (T217727)
- Added support for newer versions of the Elastica extension while maintaining backward compatibility for older version REL 1.31 (T218100)
- Added multiple new keyboard layouts in UniversalLanguageSelector.
- 2019.01: https://translatewiki.net/mleb/MediaWikiLanguageExtensionBundle-2019.01.tar.bz2
- sha256sum: 39f2e946e360ac868744dc8e6f62cb5723447415bd11bcbb4911eb0f3674360c [1]
- Announcement and Release Notes
- Compatible with MediaWiki 1.31, 1.32 and above and requires PHP 5.5.9 or above.
- $wgTranslateCC is deprecated now. It should be replaced by TranslatePostInitGroups hook. (T212836)
- Added proofreading to (Language|MessageGroup)Stats. The statistics table also has updated styling. (T41279)
- Skipping messages Special:Translate's page mode no longer sometimes marks the translation proofread. (T206748)
- Translatable subpages are no longer moved when moving parent. (T114592)
- Message group stats updating was broken in multiple ways. (T134252, T208521)
- Added multiple new keyboard layouts in UniversalLanguageSelector.
- 2018.10: https://translatewiki.net/mleb/MediaWikiLanguageExtensionBundle-2018.10.tar.bz2
- sha256sum: c0a65956d4f8e49ba1b401372636b9575a5c17fbf2501fa14ff1c265dd778862 [1]
- Announcement and Release Notes
- Compatible with MediaWiki 1.30, 1.31 and above and requires PHP 5.5.9 or above.
- Updated cldr to version 34.0
- LocalisationUpdates and UniversalLanguageSelector has removed PHP entry point. Please update your configuration!
- Fixed an error in Translate that prevented Special:PageMigration from working.
- UniversalLanguageSelector now supports UI language change when Global Preferences are present. (T198206)
- UniversalLanguageSelector dropped support for discontinued freegeoip.net.
- 2018.07: https://translatewiki.net/mleb/MediaWikiLanguageExtensionBundle-2018.07.tar.bz2
- sha256sum: 36aa80c78be6dcfb533f96dc25afdabd2fd4716452c1b5a6f2bc982def1af7bc [1]
- Announcement and Release Notes
- Compatible with MediaWiki 1.30, 1.31 and above and requires PHP 5.5.9 or above.
- Updated cldr to version 33.
- Special:SupportedLanguages: List of authors is now sorted by the number of contributions.
- Message keys coming from external files are now handled with more care and less likely to produce invalid or inaccessible pages. (T193023)
- refresh-translatable-pages.php script can now use JobQueue, which is more efficient on wikis with thousands of translatable pages. (T195347)
- Custom languages defined in $wgExtraLanguages now always appear in Special:Translate and Special:SearchTranslations. (T112889)
Télécharger avec Git
Dans le répertoire de vos extensions exécutez ce qui suit pour obtenir ou pour mettre à jour avec la dernière version et suivez les instructions de configuration ci-dessous.
for ext in Babel cldr CleanChanges LocalisationUpdate Translate UniversalLanguageSelector
do
if [ ! -d "$ext" ]
then
git clone https://gerrit.wikimedia.org/r/mediawiki/extensions/$ext.git
fi
cd $ext; git fetch --tags; git checkout 2020.10; cd ..
done
Installation
Installation requirements
Installation requirements of each piece of provided software are included in the respective documentation. See in particular:
Add/update your LocalSettings.php
Near the end of LocalSettings.php, you have to place this configuration:
wfLoadExtension( 'Babel' );
wfLoadExtension( 'cldr' );
wfLoadExtension( 'CleanChanges' );
$wgCCTrailerFilter = true;
$wgCCUserFilter = false;
$wgDefaultUserOptions['usenewrc'] = 1;
wfLoadExtension( 'LocalisationUpdate' );
$wgLocalisationUpdateDirectory = "$IP/cache";
wfLoadExtension( 'Translate' );
$wgGroupPermissions['user']['translate'] = true;
$wgGroupPermissions['user']['translate-messagereview'] = true;
$wgGroupPermissions['user']['translate-groupreview'] = true;
$wgGroupPermissions['user']['translate-import'] = true;
$wgGroupPermissions['sysop']['pagetranslation'] = true;
$wgGroupPermissions['sysop']['translate-manage'] = true;
$wgTranslateDocumentationLanguageCode = 'qqq';
$wgExtraLanguageNames['qqq'] = 'Message documentation'; # No linguistic content. Used for documenting messages
wfLoadExtension( 'UniversalLanguageSelector' );
Update database tables
Command line
In the directory where your LocalSettings.php is located, run the following command:
php maintenance/update.php
Web browser
Go to example.com/mediawiki/mw-config/ (see Manual:Upgrading#Web browser) by using your domain and path and rerun install.
Configuring and using extensions
See the respective extension documentation pages. Do note that LocalisationUpdate does nothing by default and needs additional configuration to be run periodically.
- https://www.mediawiki.org/wiki/Extension:Babel
- https://www.mediawiki.org/wiki/Extension:CLDR
- https://www.mediawiki.org/wiki/Extension:CleanChanges
- https://www.mediawiki.org/wiki/Extension:LocalisationUpdate
- https://www.mediawiki.org/wiki/Extension:UniversalLanguageSelector
- https://www.mediawiki.org/wiki/Help:Extension:Translate
Contexte
MLEB n'utilise pas les branches spécifiques des versions des extensions. C'est un cliché du master qui est vérifié pour pouvoir fonctionner avec les versions de MediaWiki spécifiées. Cela signifie que toutes les extensions de MLEB doivent suivre les règles de compatibilité assurant la prise en charge des deux dernières versions les plus stables de MediaWiki de la branche master.
Les versions de MLEB sont créées avec un outil appelé Melange. Si ce code vous intéresse, par exemple parce que vous voulez modifier son code, voyez le dépôt Melange de Git.