Categories
Web Development WordPress

Translating Multiple Branches of Your Premium Plugin with Transifex

Since GravityView launched in 2014, we have used Transifex to manage translations. Our process has always relied on a single translation resource file, and we’ve had the same flow over time:

  • Create an update with new strings
  • Upload the translation file to Transifex
  • Release the update
  • In the next minor release, include any new translations from translators

Transifex recently made it easy to create resource branches using their Command Line Interface (CLI). You can read more about creating branches on their site.

We’re about to release Version 2.0 of GravityView, which includes new strings that I want to have translated before we launch, so I created a branch of the resource.

Here’s how to do it—this assumes you have Transifex installed and configured.

  1. Switch to the branch of your plugin you want translated
  2. Update the translation file to have the new strings (we use the excellent grunt-wp-i18n Grunt package to generate our plugin automatically)
  3. Run tx --version and make sure you see 0.13.x or higher. If you’re running 0.12.x, it won’t work
  4. Push the new resource to Transifex using this format: tx push -s -b "Your Branch Name" – for example, ours was tx push -s -b "2.0" because our branch name was 2.0
  5. That will now create the resource on Transifex. Go to Transifex and confirm the resource’s name. For our 2.0 branch, the resource name was 2-0--gravityview
  6. Update your Transifex config file in the plugin’s .tx directory’s config file. Change the setting to use the new resource name. For example, instead of [gravityview.gravityview] ({name of project}.{name of resource}), it is now [gravityview.2-0--gravityview]
  7. Commit the changes to your repo (see GravityView’s here)

I’m going to be adding a new develop branch as well, so that translators will be able to translate the plugin before it’s released, instead of waiting until later.

By Zack Katz

Zack Katz is the founder of GravityKit and TrustedLogin. He lives in Leverett, Massachusetts with his wife Juniper.

1 reply on “Translating Multiple Branches of Your Premium Plugin with Transifex”

Hey there, are you updating support for Infusionsoft Gravity Forms Addon, or abandoning it?

Comments are closed.