{ "info": { "author": "Terry Yin", "author_email": "terry.yinze@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Intended Audience :: Developers", "Intended Audience :: Education", "Intended Audience :: End Users/Desktop", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 2.6", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.5", "Topic :: Education" ], "description": "\n========================\nTranslate Tool in Python\n========================\n\n|PyPI latest| |PyPI Version| |PyPI License| |Docs| |Travis Build Status|\n\n\nTranslate is a simple but powerful translation tool written in python with with support for\nmultiple translation providers. By now we are integrated with Microsoft Translation API and\nTranslated MyMemory API\n\n\nWhy Should I Use This?\n----------------------\n\nThe biggest reason to use translate is make translations in a simple way without the need of much\neffort and can be used as a translation tool like command line\n\n\nInstallation\n------------\n\n.. code-block:: bash\n\n $ pip install translate\n\nOr, you can download the source and\n\n.. code-block:: bash\n\n $ python setup.py install\n\nAdd sudo in the beginning if you met problem.\n\n\nFeatures\n--------\n\n- Translate your outputs in real time\n- Do translation in your terminal using command line\n\nUsage\n-----\n\nIn your command-line:\n\n.. code-block:: bash\n\n $ translate-cli -t zh \"This is a pen.\"\n\n Translation: \u8fd9\u662f\u4e00\u652f\u7b14\n -------------------------\n Translated by: MyMemory\n\nOr\n\n.. code-block:: bash\n\n $ translate-cli -t zh \"This is a pen.\" -o\n \u8fd9\u662f\u4e00\u652f\u7b14\n\nOptions\n~~~~~~~\n\n.. code-block:: bash\n\n $ translate-cli --help\n Usage: __main__.py [OPTIONS] TEXT...\n\n Python command line tool to make on line translations\n\n Example:\n\n $ translate-cli -t zh the book is on the table\n \u7897\u662f\u5728\u684c\u5b50\u4e0a\u3002\n\n Available languages:\n\n https://en.wikipedia.org/wiki/ISO_639-1\n Examples: (e.g. en, ja, ko, pt, zh, zh-TW, ...)\n\n Options:\n --version Show the version and exit.\n --generate-config-file Generated the config file using a Wizard and exit.\n -f, --from TEXT Sets the language of the text being translated.\n The default value is 'autodetect'.\n -t, --to TEXT Sets the language you want to translate.\n -p, --provider TEXT Set the provider you want to use. The default\n value is 'mymemory'.\n --secret_access_key TEXT Set the secret access key used to get provider\n oAuth token.\n -o, --output_only Set to display the translation only.\n --help Show this message and exit.\n\n\nChange Default Languages\n~~~~~~~~~~~~~~~~~~~~~~~~\n\nIn ~/.python-translate.cfg:\n\n.. code-block:: bash\n\n [DEFAULT]\n from_lang = autodetect\n to_lang = de\n provider = mymemory\n secret_access_key =\n\nThe cfg is not for using as a Python module.\n\nor run the command line and follow the steps:\n\n.. code-block:: bash\n\n $ translate-cli --generate-config-file\n Translate from [autodetect]:\n Translate to: \n Provider [mymemory]:\n Secret Access Key []:\n\n\nUse As A Python Module\n----------------------\n\n.. code-block:: python\n\n In [1]: from translate import Translator\n In [2]: translator= Translator(to_lang=\"zh\")\n In [3]: translation = translator.translate(\"This is a pen.\")\n Out [3]: \u8fd9\u662f\u4e00\u652f\u7b14\n\nThe result is in translation, and it\u2019s usually a unicode string.\n\n\nUse a different translation provider\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n.. code-block:: python\n\n In [1]: from translate import Translator\n In [2]: to_lang = 'zh'\n In [3]: secret = ''\n In [4]: translator = Translator(provider='microsoft', to_lang=to_lang, secret_access_key=secret)\n In [5]: translator.translate('the book is on the table')\n Out [5]: '\u7897\u662f\u5728\u684c\u5b50\u4e0a\u3002'\n\n\nDocumentation\n-------------\n\nCheck out the latest ``translate`` documentation at `Read the Docs `_\n\n\nContributing\n------------\n\nPlease send pull requests, very much appriciated.\n\n\n1. Fork the `repository `_ on GitHub.\n2. Make a branch off of master and commit your changes to it.\n3. Install requirements. ``pip install -r requirements-dev.txt``\n4. Install pre-commit. ``pre-commit install``\n5. Run the tests with ``py.test -vv -s``\n6. Create a Pull Request with your contribution\n\n\n\n.. |Docs| image:: https://readthedocs.org/projects/translate-python/badge/?version=latest\n :target: http://translate-python.readthedocs.org/en/latest/?badge=latest\n.. |Travis Build Status| image:: https://api.travis-ci.org/terryyin/translate-python.png?branch=master\n :target: https://travis-ci.org/terryyin/translate-python\n.. |PyPI Version| image:: https://img.shields.io/pypi/pyversions/translate.svg?maxAge=2592000\n :target: https://pypi.python.org/pypi/translate\n.. |PyPI License| image:: https://img.shields.io/pypi/l/translate.svg?maxAge=2592000\n :target: https://pypi.python.org/pypi/translate\n.. |PyPI latest| image:: https://img.shields.io/pypi/v/translate.svg?maxAge=2592000\n :target: https://pypi.python.org/pypi/translate\n\n\n\nChangelog\n---------\n\n3.5.0\n-----\n\n* Add sphinx documentation\n* Update readme.\n\n3.4.1\n-----\n\n* Makefile: Add a make release command\n* Add twine to dev requirements.\n\n3.4.0\n-----\n\n* Refactor: Create a folder to add all providers instead to let in a single file\n* Add Microsoft provider\n* Add more documentation to all providers (Translated-MyMemory and Microsoft Translator)\n* Add arguments to change the default provider using translate-cli\n\n\n3.3.0\n-----\n\n* Refactor translate-cli (command line interface) Using Click library instead of ArgParser\n* Unify translate-cli and main to avoid duplicate code\n* Add documentation to be used on helper commands on translate-cli\n* Remove unnecessary code\n* Refactor setup to complete information in the PKG-INFO used by PyPI\n\n\n3.2.1\n-----\n\n* Change the license from \"BEER-WARE\" to MIT\n\n3.2.0\n-----\n\n* Add multiple providers suport\n\n3.1.0\n-----\n\n* Apply Solid Principles\n* Organize Project\n* Add pre-commit, pytest\n* Add new Make file\n* Add new test cases\n\n3.0.0\n-----\n\n* General Refactor\n* Remove urllib to use requests\n* Refactor methods names removing google from then\n* Apply PEP8\n* Change contructor to keep it the code simple\n\n2.0.0 (2017-11-08)\n------------------\n\n* initial release using changes file\n\n\n", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/terryyin/google-translate-python", "keywords": "translate translation command line", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "translate", "package_url": "https://pypi.org/project/translate/", "platform": "", "project_url": "https://pypi.org/project/translate/", "project_urls": { "Homepage": "https://github.com/terryyin/google-translate-python" }, "release_url": "https://pypi.org/project/translate/3.5.0/", "requires_dist": [ "click", "lxml", "pre-commit", "requests", "tox" ], "requires_python": "", "summary": "This is a simple, yet powerful command line translator with google translate behind it. You can also use it as a Python module in your code.", "version": "3.5.0" }, "last_serial": 3381617, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "1d61382616fd28653d613c453100b80e", "sha256": "8b1e750d9ea59edfcf9a20b04c7422924c30ecf571562d4e2d6e37ce0505f1a4" }, "downloads": -1, "filename": "translate-0.0.1.tar.gz", "has_sig": false, "md5_digest": "1d61382616fd28653d613c453100b80e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3157, "upload_time": "2013-05-08T04:37:13", "url": "https://files.pythonhosted.org/packages/57/4f/22aeb57cce80b3cbb65000d6f0854ea8b6c8fb6a1acb2dd4922a6c1e633b/translate-0.0.1.tar.gz" } ], "0.0.2": [ { "comment_text": "", "digests": { "md5": "8453c4885481ffdcf89b8e57c7b56ac1", "sha256": "7410bbb2eed76d7dfc10573daa69ee84df150eb07a179ccca985f3c0f33b9455" }, "downloads": -1, "filename": "translate-0.0.2.tar.gz", "has_sig": false, "md5_digest": "8453c4885481ffdcf89b8e57c7b56ac1", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3158, "upload_time": "2013-05-08T04:40:57", "url": "https://files.pythonhosted.org/packages/43/67/76ba8621aff38c8b233fb6f15fbd3087bf040e1f9bba8a8ae3ae5e64cbe9/translate-0.0.2.tar.gz" } ], "0.0.3": [ { "comment_text": "", "digests": { "md5": "60c7e236440cb82f5d714e6d9bb0d3aa", "sha256": "1fbe5f8c3564714e64d4a619dfec2069888382cba5c3c15dbcc1a2243ef90231" }, "downloads": -1, "filename": "translate-0.0.3.tar.gz", "has_sig": false, "md5_digest": "60c7e236440cb82f5d714e6d9bb0d3aa", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3159, "upload_time": "2013-05-08T04:52:53", "url": "https://files.pythonhosted.org/packages/05/46/74781adc2cb9de73e509d39db411b75c5e42bd6eb0ce5688dbd069afd5fd/translate-0.0.3.tar.gz" } ], "0.0.4": [ { "comment_text": "", "digests": { "md5": "dec6b002f1813892d95eb0f38ef71b34", "sha256": "827e5bb69686fef7334560e528ca4211d29c12e5fbea767dd1a5f3a600d3fbb0" }, "downloads": -1, "filename": "translate-0.0.4.tar.gz", "has_sig": false, "md5_digest": "dec6b002f1813892d95eb0f38ef71b34", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2971, "upload_time": "2013-05-08T05:14:05", "url": "https://files.pythonhosted.org/packages/91/05/9f82d780a14572662040a2ca1680e22dbb80f176544aaddf1e488ea73ba1/translate-0.0.4.tar.gz" } ], "0.0.5": [ { "comment_text": "", "digests": { "md5": "4b4015c82306440ed51657ff14a55801", "sha256": "8b7045062ea329e49b8f08caf64627e87ce23568bcade55606264614d82c9361" }, "downloads": -1, "filename": "translate-0.0.5.tar.gz", "has_sig": false, "md5_digest": "4b4015c82306440ed51657ff14a55801", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3353, "upload_time": "2014-03-21T02:42:58", "url": "https://files.pythonhosted.org/packages/6e/4c/f57b3cb9f9ae8313874827a1328b66c76ac08201483f8be7c98d273353c3/translate-0.0.5.tar.gz" } ], "0.0.6": [ { "comment_text": "", "digests": { "md5": "0fc76256eb1ed53c834972193e09548b", "sha256": "0b2189ea90bff4fa36b145ecd23c397c63142bd797d44c33197f08a06d0a9aaf" }, "downloads": -1, "filename": "translate-0.0.6.tar.gz", "has_sig": false, "md5_digest": "0fc76256eb1ed53c834972193e09548b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3434, "upload_time": "2014-04-08T02:29:39", "url": "https://files.pythonhosted.org/packages/fc/d4/662ba146dd823b3052906bb38f6b6fad6bdb717fc9dd8bee3059bdb7c7ec/translate-0.0.6.tar.gz" } ], "1.0.7": [ { "comment_text": "", "digests": { "md5": "1afcb5396b3351bb92c839efd2066927", "sha256": "4478c22daead543040fc0273a9fa40f1b2eb76580991e58aa143a310c55f0e16" }, "downloads": -1, "filename": "translate-1.0.7.tar.gz", "has_sig": false, "md5_digest": "1afcb5396b3351bb92c839efd2066927", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3230, "upload_time": "2015-02-14T15:23:03", "url": "https://files.pythonhosted.org/packages/b7/d2/1a05b1c1973840581ea9aca91b8b61e4d8fc4f248b3a703fc089b9f6fd3d/translate-1.0.7.tar.gz" } ], "1.0.8": [ { "comment_text": "", "digests": { "md5": "1a54ef991c10a0905e776cd2bfbf263c", "sha256": "8db7080a883c46b952c8da95120903ab10ef257e9eb72880072b57a198efd07d" }, "downloads": -1, "filename": "translate-1.0.8.tar.gz", "has_sig": false, "md5_digest": "1a54ef991c10a0905e776cd2bfbf263c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3548, "upload_time": "2015-03-30T00:13:40", "url": "https://files.pythonhosted.org/packages/03/bf/fb5105ed36d83d152e743020dc3bbb28063061d52c77d7c54884151577df/translate-1.0.8.tar.gz" } ], "2.0.0": [ { "comment_text": "", "digests": { "md5": "587508223d5baa7aaae8161dd3d26b8f", "sha256": "e2f5397c2896de0df129ab1ede87d89921a242a93454cd7039c044ca6d5b8947" }, "downloads": -1, "filename": "translate-2.0.0.tar.gz", "has_sig": false, "md5_digest": "587508223d5baa7aaae8161dd3d26b8f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3782, "upload_time": "2015-04-13T02:37:12", "url": "https://files.pythonhosted.org/packages/be/8b/8eaba1ff2aa71c114bd934bc3a2b2d08708194ff11d6333ff6903fe68489/translate-2.0.0.tar.gz" } ], "3.1.0": [ { "comment_text": "", "digests": { "md5": "bf80f6fb79c8a9eb1380817a55527e52", "sha256": "826b4baee4893568bdac9d228353d6064349981f5d15dca353b92e086354126b" }, "downloads": -1, "filename": "translate-3.1.0.tar.gz", "has_sig": false, "md5_digest": "bf80f6fb79c8a9eb1380817a55527e52", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4545, "upload_time": "2017-11-11T08:30:36", "url": "https://files.pythonhosted.org/packages/78/6c/16415467f5835651a4dffc59bd44316cf0dc46ef98358814e51a7e83b9cf/translate-3.1.0.tar.gz" } ], "3.2.0": [ { "comment_text": "", "digests": { "md5": "0f9c151805261993c3d17547a6a68976", "sha256": "4919728699118c3cf22933b07f984ca84f2b1f62585c33e195170e18e28d54bf" }, "downloads": -1, "filename": "translate-3.2.0.tar.gz", "has_sig": false, "md5_digest": "0f9c151805261993c3d17547a6a68976", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5162, "upload_time": "2017-11-22T02:09:29", "url": "https://files.pythonhosted.org/packages/ee/05/f05ec63f9dd7704761a3e17d759d80a55f7c34337876f997d3af41621178/translate-3.2.0.tar.gz" } ], "3.2.1": [ { "comment_text": "", "digests": { "md5": "8b8f639cae34f8b06fbc7f21ee32f473", "sha256": "67195689452c11da9e07af263db667d6045a32881bce0846aa0983746772e5d0" }, "downloads": -1, "filename": "translate-3.2.1-py3-none-any.whl", "has_sig": false, "md5_digest": "8b8f639cae34f8b06fbc7f21ee32f473", "packagetype": "bdist_wheel", "python_version": "3.6", "requires_python": null, "size": 8171, "upload_time": "2017-11-23T02:09:56", "url": "https://files.pythonhosted.org/packages/13/e9/ec6125d79a4d17a8d42446ef03d587c71fa391671113bd8742741f79d7c5/translate-3.2.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "2969a06fe5c41412d421a202078c952d", "sha256": "3f3e63ba00b88d4197c7ee1478f732a482797cf825b40af0cc678fdb39c25981" }, "downloads": -1, "filename": "translate-3.2.1.tar.gz", "has_sig": false, "md5_digest": "2969a06fe5c41412d421a202078c952d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5170, "upload_time": "2017-11-23T02:09:52", "url": "https://files.pythonhosted.org/packages/1f/d2/fa424381746565be7dd2eab0b20f1649af22e85b8e353eaf0e4cd35426d0/translate-3.2.1.tar.gz" } ], "3.4.0": [ { "comment_text": "", "digests": { "md5": "dda2a0c9241eaf0cb0acc8582b7ef2d5", "sha256": "5cfd9e0b6b99e16d80689915067fdce0250000eff17ba2bd9daaf673e7963ece" }, "downloads": -1, "filename": "translate-3.4.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "dda2a0c9241eaf0cb0acc8582b7ef2d5", "packagetype": "bdist_wheel", "python_version": "3.6", "requires_python": null, "size": 12896, "upload_time": "2017-11-28T01:49:47", "url": "https://files.pythonhosted.org/packages/ca/9f/2a4b8cea950a3d752c4927a272b77f1ad9b66ebdf1e6ce08e5ae6680548a/translate-3.4.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "67fd380cfacfd1ee76c8346a5f338c74", "sha256": "2e1e7d78c1d0044b04e97da5121c52e13c993d963ee574c22fe0817217225e98" }, "downloads": -1, "filename": "translate-3.4.0.tar.gz", "has_sig": false, "md5_digest": "67fd380cfacfd1ee76c8346a5f338c74", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8119, "upload_time": "2017-11-28T01:49:43", "url": "https://files.pythonhosted.org/packages/01/80/45c44f36757430ca4ea57670bcdb71c78b89d2712e44d8ab2387493de4cd/translate-3.4.0.tar.gz" } ], "3.5.0": [ { "comment_text": "", "digests": { "md5": "1c5520c423517de7ff46a751fc893adf", "sha256": "97f82706ef92b31a778bf21b688927586919f9b3d615c95a3c53ca260558f665" }, "downloads": -1, "filename": "translate-3.5.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "1c5520c423517de7ff46a751fc893adf", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 14111, "upload_time": "2017-12-02T01:35:54", "url": "https://files.pythonhosted.org/packages/85/b2/2ea329a07bbc0c7227eef84ca89ffd6895e7ec237d6c0b26574d56103e53/translate-3.5.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "ce2c0f2ff36fb240167daf5e9e6bf2b4", "sha256": "540ef1605b73b9469720f6319137d53354febc2fa0b8152590ae086735b9be42" }, "downloads": -1, "filename": "translate-3.5.0.tar.gz", "has_sig": false, "md5_digest": "ce2c0f2ff36fb240167daf5e9e6bf2b4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16667, "upload_time": "2017-12-02T01:35:58", "url": "https://files.pythonhosted.org/packages/1f/ab/5d5987a6fcea1ab8785ca6100c4d3ef8c53069633626121026e26cb37a23/translate-3.5.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "1c5520c423517de7ff46a751fc893adf", "sha256": "97f82706ef92b31a778bf21b688927586919f9b3d615c95a3c53ca260558f665" }, "downloads": -1, "filename": "translate-3.5.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "1c5520c423517de7ff46a751fc893adf", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 14111, "upload_time": "2017-12-02T01:35:54", "url": "https://files.pythonhosted.org/packages/85/b2/2ea329a07bbc0c7227eef84ca89ffd6895e7ec237d6c0b26574d56103e53/translate-3.5.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "ce2c0f2ff36fb240167daf5e9e6bf2b4", "sha256": "540ef1605b73b9469720f6319137d53354febc2fa0b8152590ae086735b9be42" }, "downloads": -1, "filename": "translate-3.5.0.tar.gz", "has_sig": false, "md5_digest": "ce2c0f2ff36fb240167daf5e9e6bf2b4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16667, "upload_time": "2017-12-02T01:35:58", "url": "https://files.pythonhosted.org/packages/1f/ab/5d5987a6fcea1ab8785ca6100c4d3ef8c53069633626121026e26cb37a23/translate-3.5.0.tar.gz" } ] }