Skip to content

Latest commit

 

History

History
124 lines (77 loc) · 4.37 KB

README.md

File metadata and controls

124 lines (77 loc) · 4.37 KB

Package for the Laravel translation manager and database : Transl.me

GitHub Tests Action Status GitHub PHPStan Action Status GitHub Code Style Action Status Latest Version on Packagist Total Downloads


This package allows for pushing and pulling your Laravel localized content (translation files by default) to Transl.me.

Tip

Transl is a platform for developers, product owners, managers and translators to easily manage and automate localized content in a Laravel application. Localisation shouldn't be a burden on developers, it should be a burden on us.

Installation

You can install the package via composer:

composer require transl-me/laravel-transl

You can publish the config file with:

php artisan vendor:publish --tag="transl-config"

You can check out what the contents of the published config file will be here: config/transl.php.

Usage (Available commands)

Init

A one time command that initializes the defined project (pushes the initial translation lines) on Transl.me.

php artisan transl:init

Check out the command's signature to learn more about it's possible options.

Push

Pushes the defined project's translation lines to Transl.me.

php artisan transl:push

Check out the command's signature to learn more about it's possible options.

Pull

Retrieves and stores the defined project's translation lines from Transl.me.

php artisan transl:pull

Note

Unfortunately, when using with local translation files, we cannot guarantee the preservation of the original language file's formatting. This is because the language file contents are sent and retreive as JSON to and from Transl through HTTP. Therefore, any dynamic content and variables inside your translation files will be evualuated before being sent to Transl. No formatting information is transfered. Upon retrieval, the file's contents are reconstructed without the previously lost formating informations.

Tip

Ensure any previous local changes are versioned.

Check out the command's signature to learn more about it's possible options.

Synch

Pulls then pushes the defined project's translation lines to Transl.me.

php artisan transl:synch

Note

Same as for the push command regarding the inability to reconstruct the translation file's original content formatting (when using with local translation files).

Tip

Ensure any previous local changes are versioned.

Check out the command's signature to learn more about it's possible options.

Analyse

Analyses the defined project's translation lines.

php artisan transl:analyse

Check out the command's signature to learn more about it's possible options.

Testing

composer test

Changelog

Please see CHANGELOG for more information on what has changed recently.

Contributing

If you're interested in contributing to the project, please read our contributing docs before submitting a pull request.

Security Vulnerabilities

Please review our security policy on how to report security vulnerabilities.

Credits

License

Please see License File for more information.