html-i18n-cli
Advanced tools
Comparing version 0.1.2 to 0.1.3
@@ -7,5 +7,5 @@ const fs = require('fs') | ||
module.exports = (htmlfile, textsfile) => { | ||
module.exports = (htmlfile, jsonfile) => { | ||
const htmlpath = path.join(process.cwd(), htmlfile) | ||
const textspath = path.join(process.cwd(), textsfile) | ||
const textspath = path.join(process.cwd(), jsonfile) | ||
const outpath = path.join(process.cwd(), `translated-${htmlfile}`) | ||
@@ -12,0 +12,0 @@ const html = fs.readFileSync(htmlpath).toString() |
{ | ||
"name": "html-i18n-cli", | ||
"version": "0.1.2", | ||
"version": "0.1.3", | ||
"description": "HTML 国际化工具", | ||
"main": "lib/index.js", | ||
"bin": { | ||
"html": "bin/index.js" | ||
"html": "bin/html.js" | ||
}, | ||
@@ -9,0 +9,0 @@ "scripts": { |
@@ -13,3 +13,3 @@ # html-i18n-cli | ||
1. 生成 json 文件 | ||
1. 生成 JSON 文件 | ||
@@ -20,3 +20,3 @@ ``` sh | ||
2. 翻译 json 文件 | ||
2. 翻译 JSON 文件 | ||
@@ -29,4 +29,7 @@ > 输入两次 Ctrl + C 终止,机翻后可手动校对 | ||
3. 还原 html 文件 | ||
* -t zh 指定[目标语言](http://api.fanyi.baidu.com/doc/21) | ||
* -n 50 指定更新频率 | ||
3. 还原 HTML 文件 | ||
``` sh | ||
@@ -33,0 +36,0 @@ html render test.html test.json |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
19295
201
49