For this guide, we use Brew to install mojito Webapp and CLI.
Setup and install
brew tap box/mojito brew install mojito-cli brew install mojito-webapp
Start the Webapp
This starts the server on http://localhost:8080. You can log in with
Create a demo repository
mojito demo-create -n Demo1
It creates a new repository called
Demo1 in the server with some translations. A resource bundle
demo.properties is copied on the local directory
Generate the localized files
cd Demo1 mojito pull -r Demo1
It goes into
Demo1 directory and generates the localized files. You can see the generated file with
Add a new string
printf "\nFOR_DEMO=Add a string for the demo" >> demo.properties mojito push -r Demo1
It adds a new string with ID
FOR_DEMO and English value
Add a string for the demo in the resource bundle and sends the modified bundle to the server.
Check in the Workbench that the string was added and is untranslated. Try adding a translation.
Generate new localized files
mojito pull -r Demo1
Finally, this generates the updated localized files with the new translation.