code: def main(from_lang, to_lang, provider, secret_access_key, output_only, text):
      
      text = ' '.join(text)
  
      kwargs = dict(from_lang=from_lang, to_lang=to_lang, provider=provider)
      if provider != DEFAULT_PROVIDER:
          kwargs['secret_access_key'] = secret_access_key
  
      translator = Translator(**kwargs)
      translation = translator.translate(text)
      if sys.version_info.major == 2:
          translation = translation.encode(locale.getpreferredencoding())
  
      if output_only:
          click.echo(translation)
          return translation
  
      click.echo('\nTranslation: {}'.format(translation))
      click.echo('-' * 25)
      click.echo('Translated by: {}'.format(translator.provider.name))
  
      return translation
docs: Python command line tool to make on line translations
  
      \b
      Example:
      \b
      \t $ translate-cli -t zh the book is on the table
      \t 碗是在桌子上。
  
      \b
      Available languages:
      \b
      \t https://en.wikipedia.org/wiki/ISO_639-1
      \t Examples: (e.g. en, ja, ko, pt, zh, zh-TW, ...)