auto-translate-json-library 1.3.2 → 1.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.MD +10 -6
- package/build/package.json +1 -1
- package/build/src/bin/cli.js +1 -1
- package/package.json +1 -1
package/README.MD
CHANGED
|
@@ -4,7 +4,7 @@ This project is used in, (and refactored from) excellent vs code extension
|
|
|
4
4
|
Auto Translate JSON
|
|
5
5
|
<https://marketplace.visualstudio.com/items?itemName=JeffJorczak.auto-translate-json>
|
|
6
6
|
|
|
7
|
-
It
|
|
7
|
+
It opens posibility to use Auto Taransation JSON
|
|
8
8
|
not just in vs code but as a library and command line interface
|
|
9
9
|
|
|
10
10
|
# Use as library
|
|
@@ -38,8 +38,6 @@ npm i auto-translate-json-library
|
|
|
38
38
|
|
|
39
39
|
do not forget to set translation engine parameters in environment variables or .env file
|
|
40
40
|
|
|
41
|
-
```shell
|
|
42
|
-
|
|
43
41
|
```shell
|
|
44
42
|
node node_modules\auto-translate-json-library\index.js --pivotTranslation=./translations/en.json
|
|
45
43
|
```
|
|
@@ -52,7 +50,7 @@ npm run build
|
|
|
52
50
|
node .\build\src\index.js --pivotTranslation=./tests/translations/en.json
|
|
53
51
|
```
|
|
54
52
|
|
|
55
|
-
```
|
|
53
|
+
```
|
|
56
54
|
# CLI PARAMETERS
|
|
57
55
|
|
|
58
56
|
mode,
|
|
@@ -133,9 +131,15 @@ ATJ_IGNORE_PREFIX=
|
|
|
133
131
|
|
|
134
132
|
You can also use .env file to store environment variables
|
|
135
133
|
|
|
136
|
-
There is also improved version of CLI for example:
|
|
134
|
+
There is also improved version of CLI (since version 1.3.2) for example:
|
|
137
135
|
|
|
138
136
|
```shell
|
|
137
|
+
npm install -g auto-translate-library
|
|
139
138
|
atj tests/translations/en.json -e google -m file
|
|
140
139
|
```
|
|
141
|
-
|
|
140
|
+
|
|
141
|
+
You can also use it with npx
|
|
142
|
+
|
|
143
|
+
```shell
|
|
144
|
+
npx auto-translate-library tests/translations/en.json -e google -m file
|
|
145
|
+
```
|
package/build/package.json
CHANGED
package/build/src/bin/cli.js
CHANGED
|
@@ -13,7 +13,7 @@ require("dotenv").config();
|
|
|
13
13
|
// Define a function to display the help message
|
|
14
14
|
function displayHelp() {
|
|
15
15
|
console.log(`🔨 Auto translate json cli v${package_json_1.version}`);
|
|
16
|
-
console.log(
|
|
16
|
+
console.log("Usage: atj [options] <inputPath>");
|
|
17
17
|
console.log("");
|
|
18
18
|
console.log("Options:");
|
|
19
19
|
console.log(" --help, -h Display this help message");
|
package/package.json
CHANGED