{ "info": { "author": "scoefield", "author_email": "scoefield@163.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Intended Audience :: Education", "Intended Audience :: End Users/Desktop", "License :: Freeware", "Operating System :: MacOS :: MacOS X", "Operating System :: Microsoft :: Windows", "Operating System :: POSIX", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Topic :: Education" ], "description": "# sangfor_trans: Free sangfor translate for Python\n\npython 3.4+ \npython 2.7+\n\n----------\nQuickstart\n----------\nYou can install it from PyPI:\n\ncode: bash\n\n $ pip install sangfor_trans\n\nor manual install: \ncode: bash\n\n $ python setup.py install\n\n\n~~~~~~~~~~~~~~~~~~~~~~~~~~~\nsingle sentence translation\n~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\ncode: python\n\n >>> from sangfor_trans import get_translate\n >>> from sangfor_trans.config import GOOGLE, BAIDU\n >>> translator = get_translate.GetTranslator(GOOGLE)\n >>> translator.translate(\"auto\", \"zh\", \"hello world. \\n this is my book\")\n u'\u4f60\u597d\uff0c\u4e16\u754c\u3002\u8fd9\u662f\u6211\u7684\u4e66'\n\n\n----------------\nsupport language\n----------------\n\n.. code:: \n\n 'afrikaans': 'af', \n 'arabic': 'ar', \n 'belarusian': 'be', \n 'bulgarian': 'bg', \n 'catalan': 'ca', \n 'czech': 'cs', \n 'welsh': 'cy', \n 'danish': 'da', \n 'german': 'de', \n 'greek': 'el', \n 'english': 'en', \n 'esperanto': 'eo', \n 'spanish': 'es', \n 'estonian': 'et', \n 'persian': 'fa', \n 'finnish': 'fi', \n 'french': 'fr', \n 'irish': 'ga', \n 'galician': 'gl', \n 'hindi': 'hi', \n 'croatian': 'hr', \n 'hungarian': 'hu', \n 'indonesian': 'id', \n 'icelandic': 'is', \n 'italian': 'it', \n 'hebrew': 'iw', \n 'japanese': 'ja', \n 'korean': 'ko', \n 'latin': 'la', \n 'lithuanian': 'lt', \n 'latvian': 'lv', \n 'macedonian': 'mk', \n 'malay': 'ms', \n 'maltese': 'mt', \n 'chinese_simplified': 'zh-CN', \n 'chinese_traditional': 'zh-TW', \n 'auto': 'auto' \n\n----------\nHow to make python third-party library and upload to PyPi\n----------\nstep1: python setup.py sdist \nstep2: pip install twine \nstep3: we need to register an account on PyPI and create a file ~/.pypirc in the local user root directory\uff08windows: the .pypirc file is in C:\\Users\\sangfor\uff09, so that we don't need to enter the account password in the future.\n```\n[distutils]\nindex-servers=pypi\n\n[pypi]\nrepository = https://upload.pypi.org/legacy/\nusername = \npassword = \n```\nstep4: Next comes the last step, uploading packaged libraries. We use twine here. If there is no installation in the environment, we need to use PIP install twine to install it first.\n```\ntwine upload dist/* \n```\nEnd: At this point, you can see your own source code package on the web page, and you can use our own Python library by using PIP install package name.", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/Scoefield/SangforTrans", "keywords": "sangfor translate translator", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "sangfor-trans", "package_url": "https://pypi.org/project/sangfor-trans/", "platform": "", "project_url": "https://pypi.org/project/sangfor-trans/", "project_urls": { "Homepage": "https://github.com/Scoefield/SangforTrans" }, "release_url": "https://pypi.org/project/sangfor-trans/0.1.5/", "requires_dist": null, "requires_python": "", "summary": "Free Sangfor Translate API with Python. Translates totally free of charge.", "version": "0.1.5" }, "last_serial": 5662211, "releases": { "0.1.1": [ { "comment_text": "", "digests": { "md5": "15de3af8869092f481e4d3dc083483f8", "sha256": "dd62edbf296ebd0c6504f2353b02a7d9aafa3206a3bc702d2cb7bcc48326edc2" }, "downloads": -1, "filename": "sangfor_trans-0.1.1.tar.gz", "has_sig": false, "md5_digest": "15de3af8869092f481e4d3dc083483f8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11837, "upload_time": "2019-07-22T15:00:54", "url": "https://files.pythonhosted.org/packages/71/e8/83797404e506ba1d5177eb6a2ed00be8cebe36a0c6583e0060c9d7d8c8d7/sangfor_trans-0.1.1.tar.gz" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "9cda911bcb09ec78dfaf3f03d3d11a81", "sha256": "1cdecd9a71cd9a6ddee14c46087ac9785a637d8697e158e9baa0d3f75de29f21" }, "downloads": -1, "filename": "sangfor_trans-0.1.2.tar.gz", "has_sig": false, "md5_digest": "9cda911bcb09ec78dfaf3f03d3d11a81", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12061, "upload_time": "2019-08-01T15:00:04", "url": "https://files.pythonhosted.org/packages/90/b5/11ce6d66bc437cf3ca547e3215a9e40801f6f861e477439d246f4e9b240c/sangfor_trans-0.1.2.tar.gz" } ], "0.1.5": [ { "comment_text": "", "digests": { "md5": "8298ed575cbeb98ddf57e90e25622757", "sha256": "063afd2083e552f5769460278a1c451025c76fa1084f884c0aa791de11e17a66" }, "downloads": -1, "filename": "sangfor_trans-0.1.5.tar.gz", "has_sig": false, "md5_digest": "8298ed575cbeb98ddf57e90e25622757", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11666, "upload_time": "2019-08-11T14:00:51", "url": "https://files.pythonhosted.org/packages/2f/7a/15c5fcb078b01777d4ec62dd57b8ba24a71721a11a0066574e864ecbb592/sangfor_trans-0.1.5.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "8298ed575cbeb98ddf57e90e25622757", "sha256": "063afd2083e552f5769460278a1c451025c76fa1084f884c0aa791de11e17a66" }, "downloads": -1, "filename": "sangfor_trans-0.1.5.tar.gz", "has_sig": false, "md5_digest": "8298ed575cbeb98ddf57e90e25622757", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11666, "upload_time": "2019-08-11T14:00:51", "url": "https://files.pythonhosted.org/packages/2f/7a/15c5fcb078b01777d4ec62dd57b8ba24a71721a11a0066574e864ecbb592/sangfor_trans-0.1.5.tar.gz" } ] }