Languine provides a CLI to help you translate your application.
The translate command is used to translate your application.
npx languine@latest translate
The init command is used to initialize a new Languine project.
npx languine@latest init
The auth command is used to authenticate with Languine.
npx languine@latest auth
The sync command is used to sync your application with Languine.
npx languine@latest sync
The locale command is used to manage your application's locales.
npx languine@latest locale add pt,fr
The locale remove command is used to remove a locale from your application.
npx languine@latest locale remove pt,fr
The overrides command is used to manage translation overrides in your application saved in languine.ai. Overrides allow you to customize specific translations from the Languine Dashboard.
The overrides pull command is used to pull the latest overrides from the Languine Dashboard
npx languine@latest overrides pull
Sometimes you may want to get overrides for the source locale. For example, as a developer you might add translations in en.json but want to have spell checks, overrides and maintain consistent tone with other languages. You can enable this by adding your source locale to the target locales as follows:
{ "locale": { "source": "en", "targets": [ "sv", "en" <- Add your source locale here ] }, "files": { "json": { "include": [ "src/locales/[locale]/*.json" ] } } }
The translations delete command is used to delete all target translation files and remote translations from your project. This is useful when you want to start fresh or remove all translations.
npx languine@latest translations delete