Skip to main content

Simple command-line tool for translating

Project description

pytra

Preface

pytra is a simple command-line tool that translates stuff. It uses googletrans library for this purposes. pytra is capable of translating (and detecting the source language) words, sentences and even files.

Installation

Using pip

python>3.7 required:

 $ pip install pytra

Usage

pytra is very easy to use. It has several subcommands:

  • detect -- detect languages
  • detect-file -- detect file's language.
  • show-language-code -- show language codes.
  • translate -- translate stuff
  • translate-file -- text file to translate

Also soon pytra will be capable of pipelining

You can use -h or --help option with each subcommand for more details as follows:

 $ pytra <subcommand> [-h|--help]

Examples

Translate a sentence to French:

$ pytra translate "hello, world" -t fr
Bonjour le monde

Project details


Release history Release notifications | RSS feed

This version

0.3

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pytra-0.3.tar.gz (3.5 kB view details)

Uploaded Source

Built Distribution

pytra-0.3-py3-none-any.whl (5.8 kB view details)

Uploaded Python 3

File details

Details for the file pytra-0.3.tar.gz.

File metadata

  • Download URL: pytra-0.3.tar.gz
  • Upload date:
  • Size: 3.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.3.1 requests-toolbelt/0.9.1 tqdm/4.47.0 CPython/3.7.7

File hashes

Hashes for pytra-0.3.tar.gz
Algorithm Hash digest
SHA256 1841556f8c47fb82197bf83a27cc204f46676d687aa4b21658a064180071d089
MD5 9b95a090743fe3f121a1d3776123925f
BLAKE2b-256 599e353fe7abe8ccfd73d3643e1873d32a1dfb35a3df0c90399fd78723331d1d

See more details on using hashes here.

File details

Details for the file pytra-0.3-py3-none-any.whl.

File metadata

  • Download URL: pytra-0.3-py3-none-any.whl
  • Upload date:
  • Size: 5.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.3.1 requests-toolbelt/0.9.1 tqdm/4.47.0 CPython/3.7.7

File hashes

Hashes for pytra-0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 66ae59c5c86ad2db2466750a8851f3d824f69c9652279c22162d9b275a85652a
MD5 f6bb85e1bcf4fc28ae1c15ec9f265791
BLAKE2b-256 7a53bf6a8b386a94c47242fbe481d5acbb064f55086f7f5d1404568ff2883bd6

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page