io.sitoolkit.bt:sit-bt-maven-plugin

SI-Toolkit Random Data Generator

License

License

Categories

Categories

Maven Build Tools
GroupId

GroupId

io.sitoolkit.bt
ArtifactId

ArtifactId

sit-bt-maven-plugin
Last Version

Last Version

0.9
Release Date

Release Date

Type

Type

maven-plugin
Description

Description

SI-Toolkit Random Data Generator

Download sit-bt-maven-plugin

How to add to project

<plugin>
    <groupId>io.sitoolkit.bt</groupId>
    <artifactId>sit-bt-maven-plugin</artifactId>
    <version>0.9</version>
</plugin>

Dependencies

compile (4)

Group / Artifact Type Version
io.sitoolkit.bt : sit-bt-core jar 0.9
org.apache.maven : maven-plugin-api jar 3.3.9
org.apache.maven : maven-core jar 3.3.9
org.apache.maven : maven-compat jar 3.3.9

provided (2)

Group / Artifact Type Version
org.apache.maven : maven-artifact jar 3.3.9
org.apache.maven.plugin-tools : maven-plugin-annotations jar 3.5

test (3)

Group / Artifact Type Version
org.apache.maven.plugin-testing : maven-plugin-testing-harness jar 3.3.0
junit : junit jar 4.13
commons-io : commons-io jar 2.8.0

Project Modules

There are no modules declared in this project.

日本語

Batch Translator

The Batch Translator is a CLI tool for translating text files. The primary intended audience is OSS development project members who need to translate the README or documentation. The main usage is as follows.

  • Translation of a single file, such as README. md
  • Bulk translation of files with a specific extension under the directory, such as AsciiDoctor (https://asciidoctor.org/) - based documents)

Consumer

Execution Environment

The following software is required to run the Batch Translator :

  • Java 11+
  • Maven 3.6 + for use as Maven Plugin

Usage

Run the Batch Translator as a Java command or as a Maven Plugin.

  1. Create API Key (Create #API Key)
  2. Run as a Java Command or as a Maven Plugin

Creating an API Key

The Batch Translator uses "Minna no Hon' yaku @ TexTra ®" as its translation engine. To use the translation function, create an account at the following site.

https://mt-auto-minhon-mlt.ucri.jgn-x.jp/

After you create the account, click the Settings Page (in https://mt-auto-minhon-mlt.ucri.jgn-x.jp/content/setting/user/edit/), save the user ID, API KEY, and API SECRET in the sit-at. properties file.

Create a directory named. sitoolkit under the user home directory and save the sit-at. properties file there.

  • Windows
mkdir %USERPROFILE%\.sitoolkit
notepad %USERPROFILE%\.sitoolkit\sit-bt.properties
  • macOs
mkdir ~/.sitoolkit
nano ~/.sitoolkit/sit-bt.properties
  • sit-at.properties
api_key=your_api_key
api_secret=your_api_secret
name=your_user_name

Run with ####Java commands

curl -o sit-bt-0.8.jar https://repo1.maven.org/maven2/io/sitoolkit/bt/sit-bt-core-0.9.jar

java -jar sit-bt-0.8.jar -m Mode target

Example 1) Command to translate README _ ja. md from Japanese to English and to output to README. md

java -jar sit-bt-0.8.jar -m ja2en README_ja.md:README.md

Example 2) Command to translate all files with adoc extension under docs directory from Japanese to English and output to docs/en directory

java -jar sit-bt-0.8.jar -m ja2en -p *.adoc docs:docs/en

Run as Maven Plugin

Add the Batch Traslator Maven Plugin to pom. xml.

  • pom.xml
<bulid>
  <plugins>
    <plugin>
        <groupId>io.sitoolkit.bt</groupId>
        <artifactId>sit-bt-maven-plugin</artifactId>
        <version>0.9</version>
    </plugin>
  </plugins>
</build>
mvn sit-bt:translate -Dmode=ja2en -Dtarget=README_ja.md:README.md

bug reports, feature requests

If you have a bug or feature request related to the Batch Translator, please issue an issue to https://github.com/sitoolkit/sit-bt/issues).

license

The Batch Translator is exposed at Apache Lisence 2.0.

io.sitoolkit.bt

SI-Toolkit

Tools for smart system development

Versions

Version
0.9
0.8