{ "info": { "author": "PengMo", "author_email": "qinmetec@163.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Environment :: Console", "Programming Language :: Python", "Topic :: Scientific/Engineering :: Mathematics", "Topic :: Software Development :: Documentation", "Topic :: Text Processing :: Markup", "Topic :: Text Processing :: Markup :: HTML", "Topic :: Text Processing :: Markup :: LaTeX" ], "description": "LaTeX2Markdown\n==============\n\nAn `AMS-LaTeX `_ compatible\nconverter from (a subset of) `LaTeX `_ to\n`MathJaX `_ compatible\n`Markdown `_.\n\nAnyone who writes LaTeX documents using the AMS-LaTeX packages\n(``amsmath``, ``amsthm``, ``amssymb``) and wants to convert these\ndocuments to Markdown format to use with MathJaX. These Markdown files\ncan then be easily added to any web platform - Jekyll blogs, Wordpress,\nbasic HTML sites, etc.\n\nIn short, if you seek to use MathJaX to view your LaTeX documents\nonline, then you might be interested in this.\n\nDemonstration\n-------------\n\nCheck out\n`tullo.ch/projects/LaTeX2Markdown `_\nfor a live demonstration of the converter.\n\nGetting Started\n---------------\n\nInstallation\n~~~~~~~~~~~~\n\nThe project is available on PyPI, so getting it is as simple as using\n\n::\n\n pip install latex2markdown-bbsmp\n\nor\n\n::\n\n easy_install latex2markdown-bbsmp\n\nUsage\n~~~~~\n\nThe utility can be called from the command line, or from within a Python\nscript.\n\nFor the command line, the syntax to convert a LaTeX file to a Markdown\nfile is as follows:\n\n::\n\n python -m latex2markdown-bbsmp path/to/latex/file path/to/output/markdown/file t\n\nFor example, to compile a LaTeX file ``sample.tex`` into a Markdown file\n``sample.md``, call\n\n::\n\n python -m latex2markdown-bbsmp sample.tex sample.md\n\nTo use it within a Python script (to extend it, modify output, etc.),\nyou can use it as follows:\n\n::\n\n import latex2markdown\n with open(\"latex_file.tex\", \"r\") as f:\n latex_string = f.read()\n\n l2m = latex2markdown.LaTeX2Markdown(latex_string)\n\n markdown_string = l2m.to_markdown()\n\n with open(\"markdown_file.md\", \"w\") as f:\n f.write(markdown_string)\n\nFinally, add the following snippet to your HTML when loading this\ndocument.\n\n::\n\n \n \n\nFor a working example, have a look at the source of the\n`tullo.ch `_ homepage\n`here `_.\n\nWhy not use Pandoc?\n-------------------\n\n`Pandoc `_\nis an excellent document converter for less complex LaTeX documents.\nIndeed, I've used it to convert this README document to a reST version\nfor use on PyPI.\n\nUnfortunately, it is not designed to deal with documents that use the\nAMSTeX extensions - which include the theorem, lemma, proof, and\nexercise environments that are heavily used for typesetting papers,\nlecture notes, and other documents.\n\nAs neither Pandoc nor MathJaX can deal with these documents, I hacked\ntogether a set of regular expressions that can convert a subset of LaTeX\nto Markdown, and used a few more to convert the sMarkdown to\nMathJaX-convertible Markdown.\n\nExample\n-------\n\nAs an example, the following LaTeX code:\n\n::\n\n \\section{Example Section}\n \\begin{thm}[Euclid]\n There are infinitely many primes.\n \\end{thm}\n\n \\begin{proof}\n Suppose that $p_1 < p_2 < \\dots < p_n$ are all of the primes. \n Let $P = 1 + \\prod_{i=1}^n p_i$ and let $p$ be a prime dividing $P$.\n\n Then $p$ can not be any of $p_i$, for otherwise $p$ would divide the \n difference $P - \\left(\\prod_{i=1}^n p_i \\right) - 1$, which is impossible. \n So this prime $p$ is still another prime, and $p_1, p_2, \\dots p_n$ \n cannot be all of the primes.\n \\end{proof}\n\nis converted into the following Markdown:\n\n::\n\n ### Example Section\n #### Theorem 1 (Euclid)\n\n > There are infinitely many primes.\n\n #### Proof\n\n Suppose that $p_1 < p_2 < \\dots < p_n$ are all of the primes. \n Let $P = 1 + \\prod_{i=1}^n p_i$ and let $p$ be a prime dividing $P$.\n\n Then $p$ can not be any of $p_i$, for otherwise $p$ would divide the difference \n $P - \\left(\\prod_{i=1}^n p_i \\right) - 1$, which is impossible. So this prime \n $p$ is still another prime, and $p_1, p_2, \\dots p_n$ cannot be all of the primes.\n\nSupported LaTeX/AMSTeX Environments\n-----------------------------------\n\n- ``emph``, ``textbf``, ``texttt``\n- ``thm``\n- ``prop``\n- ``lem``\n- ``exer``\n- ``proof``\n- ``chapter``\n- ``section``\n- ``subsection``\n- ``itemize``\n- ``enumerate``\n\nalong with everything supported by MathJax - list available\n`online `_.", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/bbsmp/LaTeX2Markdown.git", "keywords": "", "license": "", "maintainer": "", "maintainer_email": "", "name": "latex2markdown-bbsmp", "package_url": "https://pypi.org/project/latex2markdown-bbsmp/", "platform": "", "project_url": "https://pypi.org/project/latex2markdown-bbsmp/", "project_urls": { "Homepage": "https://github.com/bbsmp/LaTeX2Markdown.git" }, "release_url": "https://pypi.org/project/latex2markdown-bbsmp/0.0.4.4/", "requires_dist": null, "requires_python": "", "summary": "Forked from Andrew's masterpiece\uff1ahttps://github.com/ajtulloch/LaTeX2Markdown, An AMS-LaTeX compatible converter that maps a subset of LaTeX to Markdown/MathJaX.", "version": "0.0.4.4", "yanked": false, "yanked_reason": null }, "last_serial": 6016288, "releases": { "0.0.2": [ { "comment_text": "", "digests": { "md5": "1341486c6eec854d63760860f8fe8d02", "sha256": "e3684a6989e884ca0c60cdf448ddc4c7ea75a3787f103419cf7a02b5879d87d5" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.2.tar.gz", "has_sig": false, "md5_digest": "1341486c6eec854d63760860f8fe8d02", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10536, "upload_time": "2018-09-14T09:53:38", "upload_time_iso_8601": "2018-09-14T09:53:38.324893Z", "url": "https://files.pythonhosted.org/packages/8c/ec/ae0b2835454892f7a1bc908ce6f82fb1ae890e9bbc88ec7a89e8f4153d31/latex2markdown-bbsmp-0.0.2.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.3": [ { "comment_text": "", "digests": { "md5": "fceacc6d137cabbbd54fc9534be69d7d", "sha256": "3ffbdd292a1844d2466dedc3a99554e71ce046871edc4aaa4a3ff2490a3a2779" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.3.tar.gz", "has_sig": false, "md5_digest": "fceacc6d137cabbbd54fc9534be69d7d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41076, "upload_time": "2018-09-15T01:45:26", "upload_time_iso_8601": "2018-09-15T01:45:26.937702Z", "url": "https://files.pythonhosted.org/packages/9b/f8/07eab4ed2bcce06fbcf34e44bb0ffb5e242f6840c434104b1c6fbbdcca98/latex2markdown-bbsmp-0.0.3.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.3.1": [ { "comment_text": "", "digests": { "md5": "d0a0a5636052405e55cc07abd202429c", "sha256": "334e4023869c69b628d872ce6c3d68a570a179edbe4884180de0ad377ed226dc" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.3.1.tar.gz", "has_sig": false, "md5_digest": "d0a0a5636052405e55cc07abd202429c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41078, "upload_time": "2018-09-15T06:49:59", "upload_time_iso_8601": "2018-09-15T06:49:59.468121Z", "url": "https://files.pythonhosted.org/packages/09/0c/0aadc9fb057604aba7c07eb65bbc8f640f1b87aa3fa4b872bb77cc431bd9/latex2markdown-bbsmp-0.0.3.1.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.3.2": [ { "comment_text": "", "digests": { "md5": "f4cbc63a7fd3b66c7c634d7cbb27c40c", "sha256": "769942a584ffdde2e3e94fcb4f9580ac6fe4b6b6eb670847ccc21531f648a3fb" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.3.2.tar.gz", "has_sig": false, "md5_digest": "f4cbc63a7fd3b66c7c634d7cbb27c40c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41067, "upload_time": "2018-09-27T02:28:49", "upload_time_iso_8601": "2018-09-27T02:28:49.386325Z", "url": "https://files.pythonhosted.org/packages/3f/68/9d7da171d1940ebe9c8bdf0976d920ebb01a9d65a490915ed508f1bfdb87/latex2markdown-bbsmp-0.0.3.2.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.3.3": [ { "comment_text": "", "digests": { "md5": "cb34556d6d040e014ac0fdee9caa353b", "sha256": "44f8a30e84746b422ef65408f6562f75499f8273b271e8235a2015a269c1fcf5" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.3.3.tar.gz", "has_sig": false, "md5_digest": "cb34556d6d040e014ac0fdee9caa353b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41180, "upload_time": "2018-10-29T01:59:38", "upload_time_iso_8601": "2018-10-29T01:59:38.260809Z", "url": "https://files.pythonhosted.org/packages/1c/ab/79895831265035f28c70d88f8c188c0855da470661023a087fe5cd178169/latex2markdown-bbsmp-0.0.3.3.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.3.4": [ { "comment_text": "", "digests": { "md5": "28b2ce7704f876b9a3a6968052ec5427", "sha256": "f2d7692039c57bbc5495b6fb44ea0747462d1fb2e26668c03871dbf37762fc05" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.3.4.tar.gz", "has_sig": false, "md5_digest": "28b2ce7704f876b9a3a6968052ec5427", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41194, "upload_time": "2018-11-02T10:16:32", "upload_time_iso_8601": "2018-11-02T10:16:32.365724Z", "url": "https://files.pythonhosted.org/packages/fe/64/13c1bd9b03b166b62920436c3ce145ae1753d232b91ceee2acda0eca30b1/latex2markdown-bbsmp-0.0.3.4.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.3.5": [ { "comment_text": "", "digests": { "md5": "87049e1d8ff20056b7ecef6b612aad7a", "sha256": "5e59d1eb501195c25b7a2fb4822d96d40fa23513b44cb940c0dd1d573e76fb33" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.3.5.tar.gz", "has_sig": false, "md5_digest": "87049e1d8ff20056b7ecef6b612aad7a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41199, "upload_time": "2018-11-06T09:58:53", "upload_time_iso_8601": "2018-11-06T09:58:53.795258Z", "url": "https://files.pythonhosted.org/packages/61/67/e988c1a3c6e3eceb7a6a9ad6572d8ab100426055962e62f0d2341c3b6f95/latex2markdown-bbsmp-0.0.3.5.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.3.6": [ { "comment_text": "", "digests": { "md5": "62f7dd5255e388707297f9d1f3dd723e", "sha256": "c030058ecd979fef6599b604f3eb8eb08e9dfb25f9af2ecf8ab633a16d4b4600" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.3.6.tar.gz", "has_sig": false, "md5_digest": "62f7dd5255e388707297f9d1f3dd723e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41216, "upload_time": "2018-11-30T06:25:44", "upload_time_iso_8601": "2018-11-30T06:25:44.416116Z", "url": "https://files.pythonhosted.org/packages/bb/89/85941adedcf00260f6c9abb97cbfbe6179b4719753e5647f1322a770ee7e/latex2markdown-bbsmp-0.0.3.6.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.3.7": [ { "comment_text": "", "digests": { "md5": "e8dda2cfeb8ed9b319f8e029949b209b", "sha256": "a578508e13c10b96b26ac57338a943aea951c4af53c986fd4eb23388e47d167e" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.3.7.tar.gz", "has_sig": false, "md5_digest": "e8dda2cfeb8ed9b319f8e029949b209b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41308, "upload_time": "2019-01-19T07:47:28", "upload_time_iso_8601": "2019-01-19T07:47:28.774937Z", "url": "https://files.pythonhosted.org/packages/13/9b/e4598982c964badb229e5b9b65eb0d25a24ffb9971d4077bf58f9a1f25fa/latex2markdown-bbsmp-0.0.3.7.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.3.8": [ { "comment_text": "", "digests": { "md5": "c62c7250d3c71c9aaf40defe6ea03cb0", "sha256": "39c57b7eec6b1dfc8c36a74955d767114a13b11994ec24689295e013bb469e13" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.3.8.tar.gz", "has_sig": false, "md5_digest": "c62c7250d3c71c9aaf40defe6ea03cb0", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41323, "upload_time": "2019-01-19T08:11:41", "upload_time_iso_8601": "2019-01-19T08:11:41.876750Z", "url": "https://files.pythonhosted.org/packages/57/22/10b74560efa012ba49a20ec41d8d23aac7833e027a66392feff7de70b7f0/latex2markdown-bbsmp-0.0.3.8.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.3.9": [ { "comment_text": "", "digests": { "md5": "87f2e7882a965726a3b1237a03913f77", "sha256": "9e3b88978fc9c60bcf25947b2779c4bcd97a2f7a06082a92b5cdaae756b30545" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.3.9.tar.gz", "has_sig": false, "md5_digest": "87f2e7882a965726a3b1237a03913f77", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41459, "upload_time": "2019-01-26T02:56:19", "upload_time_iso_8601": "2019-01-26T02:56:19.717386Z", "url": "https://files.pythonhosted.org/packages/a6/54/b696e9a5ce6c0d18082a3b0bc0c6cc200a48fbde46e5fec990e79d14cfd2/latex2markdown-bbsmp-0.0.3.9.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.4.0": [ { "comment_text": "", "digests": { "md5": "e8f2f75c587242a4f06d4193fa0c5190", "sha256": "3188cd7ceb55b6d877900cd49402c6d7800e491c9e5beef88b108caedde72688" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.4.0.tar.gz", "has_sig": false, "md5_digest": "e8f2f75c587242a4f06d4193fa0c5190", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41537, "upload_time": "2019-04-13T10:13:58", "upload_time_iso_8601": "2019-04-13T10:13:58.227996Z", "url": "https://files.pythonhosted.org/packages/ca/a7/45ba11af66467a17f61439a4dc18316ad1de0784a62fed8975936da8bda3/latex2markdown-bbsmp-0.0.4.0.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.4.1": [ { "comment_text": "", "digests": { "md5": "29011836fa12b5c220f319c166837c95", "sha256": "4b12202009b2876aa2b085257ac293918250ac7459b7a5017c3c19efc6c28a40" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.4.1.tar.gz", "has_sig": false, "md5_digest": "29011836fa12b5c220f319c166837c95", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41562, "upload_time": "2019-08-27T08:47:17", "upload_time_iso_8601": "2019-08-27T08:47:17.986105Z", "url": "https://files.pythonhosted.org/packages/18/ff/6e8e37a342a46966cd20604ffd0657012e37a8443797cec4789059fd778f/latex2markdown-bbsmp-0.0.4.1.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.4.2": [ { "comment_text": "", "digests": { "md5": "0ea898afc0c536271c036d3bfbfc9ed0", "sha256": "6fa2d9b2b05b2ba3d39cb007d0438aa68de366dd060129cea67e9db78e36d088" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.4.2.tar.gz", "has_sig": false, "md5_digest": "0ea898afc0c536271c036d3bfbfc9ed0", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41638, "upload_time": "2019-10-21T07:15:35", "upload_time_iso_8601": "2019-10-21T07:15:35.527562Z", "url": "https://files.pythonhosted.org/packages/44/13/c7bdc3221486c13d81e59385c457129be165c66ac53f4d92d59d15678f07/latex2markdown-bbsmp-0.0.4.2.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.4.3": [ { "comment_text": "", "digests": { "md5": "13bd9ec2eee38fa53ecf5f0d33818fe9", "sha256": "e45de75c123a520965f5087c4fdd9fd95e91f39f248db7b79b8dad38edbb4f57" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.4.3.tar.gz", "has_sig": false, "md5_digest": "13bd9ec2eee38fa53ecf5f0d33818fe9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41648, "upload_time": "2019-10-23T02:42:09", "upload_time_iso_8601": "2019-10-23T02:42:09.610471Z", "url": "https://files.pythonhosted.org/packages/af/c0/eeff95a45a117f3f99f0c2552b8af0311700c8c6ec954dadbcb20d4fb770/latex2markdown-bbsmp-0.0.4.3.tar.gz", "yanked": false, "yanked_reason": null } ], "0.0.4.4": [ { "comment_text": "", "digests": { "md5": "e8068c5ce4e5d127b42f909d4f994949", "sha256": "7ec98b22bb268e9030d8265f42b19dde23c1670c0bfdd2c84a1a9bcc8859d415" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.4.4.tar.gz", "has_sig": false, "md5_digest": "e8068c5ce4e5d127b42f909d4f994949", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41644, "upload_time": "2019-10-23T02:58:11", "upload_time_iso_8601": "2019-10-23T02:58:11.106470Z", "url": "https://files.pythonhosted.org/packages/af/76/4c6678b7e197b9766309f7c39062eb767ef66416dd09fcefa43c35ebc077/latex2markdown-bbsmp-0.0.4.4.tar.gz", "yanked": false, "yanked_reason": null } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "e8068c5ce4e5d127b42f909d4f994949", "sha256": "7ec98b22bb268e9030d8265f42b19dde23c1670c0bfdd2c84a1a9bcc8859d415" }, "downloads": -1, "filename": "latex2markdown-bbsmp-0.0.4.4.tar.gz", "has_sig": false, "md5_digest": "e8068c5ce4e5d127b42f909d4f994949", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41644, "upload_time": "2019-10-23T02:58:11", "upload_time_iso_8601": "2019-10-23T02:58:11.106470Z", "url": "https://files.pythonhosted.org/packages/af/76/4c6678b7e197b9766309f7c39062eb767ef66416dd09fcefa43c35ebc077/latex2markdown-bbsmp-0.0.4.4.tar.gz", "yanked": false, "yanked_reason": null } ], "vulnerabilities": [] }