Skip to main content

XTM Connect – Drupal 8.x-6.2

Using the Composer installation tool (Drupal Release 9 onwards)

From Drupal Release 9, the Composer installation tool is the preferred method for installing modules (plugins). Composer replaces the previous installation methods: directly, via a module's URL, or by manually downloading a package that contains the package and then unpacking it and installing it (see Note below).

Composer simplifies module installation by automatically fetching and installing the required versions of libraries and their dependencies. This ensures that all components, including transitive dependencies, are compatible and functional. It also generates a composer.lock file to maintain consistency across environments, ensuring the same versions of dependencies are installed everywhere. By automating dependency resolution, version control, and autoloading, Composer ensures that all necessary components are installed and integrated in a Drupal site seamlessly.

Note

The Composer installation tool cannot be used if your Drupal system is pre-Release 9. Use one of these installation methods instead:

To use Composer to install the TMGMT plugin in Drupal (as a "module"):
  1. Ensure that Composer has been installed on your Drupal system server. For details, see the official Composer website.

  2. To download the TMGMT module, along with its dependencies, go to the TMGMT page: Translation Management Tool | Drupal.org.

  3. Scroll to the bottom of the page, to the Releases section. You see the details for the current (most recent) module (plugin) release.

  4. To download the current version of TMGMT, mark the text in the Install: text box, and copy it to the Clipboard.

    Example: composer require 'drupal/tmgmt:^1.17'.

    Alternatively, if the listed TMGMT release is not suitable, select the View all releases link at the bottom of the page. You will see a list of previous releases. Follow steps 5. and 6. below.

  5. To install an older version of TMGMT, select the name of the TMGMT release that you require. A page containing installation files (packages) for that release is displayed.

  6. In the Install section, at the top of the release page, mark the text in the Install: text box, and copy it to the Clipboard.

    Example: composer require 'drupal/tmgmt:^1.17'.

  7. In either case (you want to download the current version of TMGMT or an older one), the Composer installation string for that release is now stored in the Clipboard.

  8. On your computer, open the command-line interface.

  9. At the prompt, enter the path for the location at which you want to install the module (plugin), on the server on which your Drupal instance is installed. (For example, in a Windows Command Prompt window, use the cd command to change to a different path.)

  10. At the command prompt, when it is displayed, paste in the Clipboard contents (Composer installation string for the release you have selected). Then, press the appropriate key(s) to confirm your entry. (For example, in a Windows Command Prompt window, press Enter.)

    The package that contains the release installation files is unpacked and the files are extracted. When all the module files have been installed, a confirmation message is displayed on screen. You can now leave the command-line interface.

  11. To leave the command-line interface, enter the appropriate command for your operating system (example: Windows uses exit). Then, press the appropriate key(s) to confirm that you want to leave the command-line interface. (For example, in a Windows Command Prompt window, press Enter.)

Result: using Composer, you have installed the TMGMT plugin in your organization's Drupal instance.

Now install the XTM Connect – Drupal plugin on the Drupal server.

TMGMT on Drupal does not require any extra dependencies but, to enable it to be used, additional modules must also be installed and activated. See Installing and enabling required Translation Management modules in Drupal.