Deepl – Linux 命令行语言翻译工具

Deepl – Command Line Language Translator Tool for Linux
Last Updated : 14 Feb, 2021
Deepl is the best language translator command-line tool that detects the language of input text and translates it into the desired language using advanced machine learning and neural networking algorithms. It is open source and powered by a German tech Company under the MIT license.

It supports the following languages

English (EN)
Italian (IT)
Spanish (ES)
Polish (PL)
French (FR)
German (DE)
Dutch (NL)
It also provides a paid subscription for the interested user and also has a free version (Deepl — CLI Translator Tool). This article will discuss the installation steps of the Deepl — CLI Translator Tool and the use of this Tool with some examples.

Note: we will see a screenshot of only Ubuntu Linux Machine cause all Linux versions has similarity in installation process run all these command same as Ubuntu.

Installation of Deepl — CLI Translator Step-Wise
Step 1: Install the latest version of the Node.Js or If you have already installed then check the version of Node.js and it should be > 6.0

Deepl - Command Line Language Translator Tool for Linux

Step 2: Install Yarn package dependency manager in Linux Distribution

For different Linux distribution Run different Following Commands.

For Ubuntu:

curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo “deb https://dl.yarnpkg.com/debian/ stable main” | sudo tee /etc/apt/sources.list.d/yarn.list
sudo apt update && sudo apt install yarn
yarn --version
Deepl - Command Line Language Translator Tool for Linux

For Centos / Fedora / RHEL:

curl --silent --location https://dl.yarnpkg.com/rpm/yarn.repo | sudo tee /etc/yum.repos.d/yarn.repo
curl --silent --location https://rpm.nodesource.com/setup_12.x | sudo bash -
yum install yarn [On CentOS/RHEL Linux distribution ]
dnf install yarn [On Fedora Linux distribution ]
yarn --version
For Gentoo Linux:

sudo emerge --ask sys-apps/yarn
yarn --version
Installation of Deepl – CLI Translator Tool:
Step 3: Now, Install Deepl – CLI Translator Tool

yarn global add deepl-translator-cli
Deepl - Command Line Language Translator Tool for Linux

Step 4: Check Installation

deepl --version
or
./yarn/bin/deepl --version
Deepl - Command Line Language Translator Tool for Linux

Use of Deepl – CLI Translator Tool:
To Translate the text:

deepl translate -t ‘KaTeX parse error: Double superscript at position 31: …ge_ISO_code }' '̲{ Input_string }’
To detect the language:

deepl detect 'KaTeX parse error: Double superscript at position 31: …ge_ISO_code }' '̲{ Input_string }
To get a better understanding you can see the following drawing:

Deepl - Command Line Language Translator Tool for Linux

Example:

Command: deepl translate -t ‘DE’ ‘geeks for geeks is the best site’

Output : ‘geeks für geeks ist die beste Seite’

Explanation : Here given above command has three part

Initial Command Syntax to translate → deepl translate -t
target language ISO code → ‘DE’ (for german)
Sentence that you want to translate → ‘geeks for geeks is the best site’
Command : deepl detect ‘geeks for geeks is the best site’

Output : English(EN)

Explanation : Here given above command has only two part

Initial Command Syntax to translate → deepl detect
Sentence for that you want to detect language → ‘geeks for geeks is the best site’

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值