CLI tool to translate .md
files from English to Russian and back.
Can use Yandex Translation API and Google Cloud translation.
Install project:
$ pip install md-translate
You can store your default settings in .json
file.
Settings file content example:
{
"source_lang": "ru",
"target_lang": "en",
"service_name": "Google",
}
If you set config file, you should specify it with -c CONFIG_PATH
argument!
$ md-translate [-h] [-c CONFIG_PATH]
[-s {Yandex,Google}] [-S] [-T]
[path]
If you set config file, you can override any of settings by arguments
To run the source code:
$ pip uninstall md-translate
$ python -m md_translate.app md-translate [-h] [-c CONFIG_PATH]
[-s {Yandex,Google}] [-S] [-T]
[path]
path
Path to folder to process. If not set, uses current folder
-h, --help
, show this help message and exit-c CONFIG_PATH, --config_path CONFIG_PATH
, Path to config_file-s {Yandex,Google,Bing,Deepl}, --service_name {Yandex,Google,Bing,Deepl}
, Translating service-S SOURCE_LANG, --source_lang SOURCE_LANG
, Source language code-T TARGET_LANG, --target_lang TARGET_LANG
, Target language code
Now used Yandex
, Google
, Bing
, Deepl
Some of them can be not working, try it and find the most suitable for you