Got feedback or spotted a mistake?

Leave a comment at the end of this page or email contact@krishagni.com

Building Language Plugin

The intention of developing this plugin is to allow customers to update the create and update messages and see the effect immediately in OpenSpecimen (without having to wait for us to give a new build).

Once all the messages are updated and test, you can share the plugin back with us to update GitHub.

Perquisites:

Install Java 17

CentOS/ RedHat :  sudo yum install adoptopenjdk-17-hotspot

Ubuntu : sudo apt-get install openjdk-17-jdk

Set JAVA_HOME variable in .bashrc file in service/user account's home directory using below command

  • vi /home/krishagni/.bashrc

  • Add JAVA_HOME="/usr/lib/jvm/adoptopenjdk-17-hotspot-amd64" (CentOS)

  • export PATH="$PATH:/usr/lib/jvm/java-17-openjdk-amd64/bin" (for Ubuntu)

  • To reload the 'JAVA_HOME' variable execute the following command: source .bashrc

  • Check whether the 'JAVA_HOME' variable is set using following command: echo $JAVA_HOME

Install gradle 7.5.x

  • Download gradle 7.5.x from here

  • Follow Installation Steps from here

Download plugin source code from here using the below command:

            git clone https://github.com/krishagni/os-extensions.git

Create new language files or edit existing file for your country:

  1. cd os-extension/l10N/

  2. Add a new message file similar to ./src/main/ui/src/i18n/nl.json (English version)

  3. Add a new message file similar to ./src/main/webapp/app/i18n/nl.js (English version)

  4. Add new message files similar to cd ./src/main/resources/errors/messages_nl_NL.properties (English version)

  5. After editing the files, come back to l10N directory.

Important: The naming of the file should match the Java locale settings for your country. 

Commands to build plugin:

  • gradle clean

  • gradle build

Installation of plugin:

  • Stop Tomcat

  • Copy the jar from <Plugin_Dir>/build/libs in openspecimen <PLUGIN_DIR>/zustomer/ directory.

  • Start Tomcat

After all the files are translated, please send us back the plugin so that we can check it in our Github repository.

Got feedback or spotted a mistake?

Leave a comment at the end of this page or email contact@krishagni.com