A simple command line applilcaition for translating languages using ISO-639-1 Codes
To view the list of supported languages, check https://cloud.google.com/translate/docs/languages
Clone the project
git clone https://github.com/mainaksamuel/metaphrase.gitGo to the project directory
cd metaphraseInstall metaphrase
python setup.py installUse the ISO-639-1 language codes for setting the source --sl and target --tl languages.
Getting help
metaphrase --help # general help
metaphrase translate --help # help with translating texts
Setting the target language using the --tl flag
metaphrase translate --tl=de --text="How are you?"
Setting source language using the --sl flag
metaphrase translate --sl=en --tl=es --text="How was your day?"
Getting text and target language prompts.
$ metaphrase translate ↵
Enter text to translate: Howdy ↵
Enter the target language ISO-639-1 Code to translate to: fr ↵