2017 © Pedro Peláez
 

composer-plugin drupal-l10n

Composer Plugin for downloading Drupal translation files

image

drupal-composer/drupal-l10n

Composer Plugin for downloading Drupal translation files

  • Monday, July 2, 2018
  • by webflo
  • Repository
  • 3 Watchers
  • 2 Stars
  • 21 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 2 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

drupal-l10n

CI, (*1)

Composer plugin for automatically downloading Drupal translation files when using Composer to manage Drupal projects., (*2)

This plugin is useful when you want to package your project and then deploy this package on a target environment and that this environment does not have access to a localization server. So you have to prepare the translations before deploying., (*3)

It avoids you to have to put the localization files under your VCS or to have a local site to download the translations., (*4)

Usage

Run composer require drupal-composer/drupal-l10n in your composer project before installing or updating drupal/core., (*5)

Once drupal-l10n is required by your project, it will automatically download the translations files whenever composer update download new versions of Drupal projects installed. It also runs on composer require command., (*6)

You can manually download the localization files according to your configuration by using composer drupal:l10n., (*7)

Configuration

You can configure the plugin by providing some settings in the extra section of your root composer.json., (*8)

{
  "extra": {
    "drupal-l10n": {
      "destination": "translations/contrib",
      "languages": [
        "fr",
        "es"
      ]
    }
  }
}

The destination parameter may be used to specify the destination folder of the translation files. By default the destination is sites/default/files/translations., (*9)

The languages parameter specify the languages you want to retrieve., (*10)

Drupal configuration

You can say to Drupal to not download translations files by updating your configuration on the pages: * /admin/config/regional/translate/settings: Local files only option * /admin/config/media/file-system: Interface translations directory field, (*11)

or by putting the following lines in your settings.php file:, (*12)

$config['locale.settings']['translation']['path'] = 'translations/contrib';
$config['locale.settings']['translation']['use_source'] = 'local';

The Versions

02/07 2018

dev-master

9999999-dev

Composer Plugin for downloading Drupal translation files

  Sources   Download

GPL-2.0-or-later

The Requires

  • php >=5.6
  • composer-plugin-api ^1.0.0

 

The Development Requires

02/07 2018

1.0.0

1.0.0.0

Composer Plugin for downloading Drupal translation files

  Sources   Download

GPL-2.0-or-later

The Requires

  • php >=5.6
  • composer-plugin-api ^1.0.0

 

The Development Requires