Skip to content

Latest commit

 

History

History
55 lines (38 loc) · 1.28 KB

example.md

File metadata and controls

55 lines (38 loc) · 1.28 KB

Workshop-translator command examples

  1. To translate a index.md file from English to Japanese with hugo header.
mdt --path index.md
  1. To translate a index.md file from English to Japanese without hugo header (pure markdown file)
mdt --path index.md --no-hugo
  1. To translate a index.md file from English to Chinese
mdt --path index.md --from en --to zh
  1. To translate a index.md file from English to Japanese using DeepL API Free
export DEEPL_API_KEY=<YourDeepLAPIKey>
mdt --path index.md --deepl-free

You can generate a DeepL API key from this page.
The language specification method is the same when using Amazon Translate.

  1. To translate a index.md file from English to Japanese using DeepL API Pro
export DEEPL_API_KEY=<YourDeepLAPIKey>
mdt --path index.md --deepl-pro
  1. To translate a index.md file from English to Japanese using Claude v2
mdt --path index.md --claude
  1. To translate all .md files in folder samples recursively from English to Japanese
mdt -r --path samples
  1. To translate a file and output to a designated folder (name: translated) from English to Chinese
mkdir translated
mdt --path index.md --from en --to zh --output translated