Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/argshook/translate

A simple Google Translate CLI Tool
https://github.com/argshook/translate

Last synced: about 20 hours ago
JSON representation

A simple Google Translate CLI Tool

Awesome Lists containing this project

README

        

# A simple Google Translate CLI Tool

`npm` module which wraps [@vitalets/google-translate-api](https://github.com/vitalets/google-translate-api) and allows to use it as CLI.

## Install

### With `npm`

```bash
npm install -g @argshook/translate
```

### With `yarn`

```bash
yarn global add @argshook/translate
```

## Use

```txt
Usage: translate --from --to 'phrase to translate'

Options:
--version Show version number [boolean]
-f, --from Language to translate from [string]
-t, --to Language to translate to. Default is English
[string] [default: "en"]
-l, --languages List of all available languages [boolean]
--help Show help [boolean]
```

## Examples

```bash
$ translate --from uk 'Слава Україні!'
Glory to Ukraine!
```

```bash
$ translate --to ru "it's not a special operation"
Это не специальная операция
```

## Contribute

```bash
git clone [email protected]:argshook/translate.git
cd translate
npm install
node src/index.js
```