{ "info": { "author": "jeca", "author_email": "nyanvamp@gmail.com", "bugtrack_url": null, "classifiers": [ "License :: OSI Approved :: MIT License", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 3" ], "description": "[![Build Status](https://travis-ci.org/jecamanga/simples.svg?branch=master)](https://travis-ci.org/jecamanga/simples)\n[![Build Status](https://dev.azure.com/simplesgit/simples/_apis/build/status/jecamanga.simples?branchName=master)](https://dev.azure.com/simplesgit/simples/_build/latest?definitionId=1&branchName=master)\n[![Documentation Status](https://readthedocs.org/projects/simples/badge/?version=latest)](https://simples.readthedocs.io/pt/latest/?badge=latest)\n[![codecov](https://codecov.io/gh/jecamanga/simples/branch/master/graph/badge.svg)](https://codecov.io/gh/jecamanga/simples)\n\nsimples\n=======================\n\nO pacote simples cont\u00e9m a seguinte estrutura\n\n```\n simples/\n \u251c\u2500\u2500 setup.py\n |\u2500\u2500 simples/\n | |\u2500\u2500\u2500\u2500 __init__.py\n | \u2514\u2500\u2500\u2500\u2500 soma.py\n |\u2500\u2500 tests/\n | |\u2500\u2500\u2500\u2500 __init__.py\n | \u2514\u2500\u2500\u2500\u2500 test_soma.py\n \u2514\u2500\u2500 docs/\n```\n\n### Criando a pasta docs e construindo o html:\n\n**Pr\u00e9 requisitos**:\n\n* ``sphinx-build`` para construir a documenta\u00e7\u00e3o\n\nA pasta docs e seu conte\u00fado pode ser criada usando os seguintes comandos:\n\n```console\nfoo@bar:~/simples$ mkdir docs\nfoo@bar:~/simples$ cd docs\nfoo@bar:~/simples/docs$ sphinx-quickstart\nfoo@bar:~/simples/docs$ sphinx-apidoc -f -o source/ ../simples\n```\n\nDentro da pasta v\u00e1rios arquivos s\u00e3o criados, sendo alguns deles ``conf.py`` e ``index.rst``. \n\n#### Modificando o ``conf.py``\n\n* O pacote ``simples`` utiliza o padr\u00e3o de [docstring do numpy](https://numpydoc.readthedocs.io/en/latest/format.html#docstring-standard). Ent\u00e3o dever\u00e1 ser inserida essa informa\u00e7\u00e3o na lista ``extens\u00f5es`` que se encontra dentro do arquivo. \n```python\nextensions = ['sphinx.ext.autodoc',\n 'sphinx.ext.napoleon'\n]\n```\n> Para saber mais sobre docstrings voc\u00ea pode consultar alguns desses tutoriais em portugu\u00eas: [caderno de laboratorio](https://cadernodelaboratorio.com.br/2017/05/31/documentando-um-programa-python-com-docstrings-e-pydoc/) e [python help](https://pythonhelp.wordpress.com/2011/02/14/docstrings/). \n\n* Os m\u00f3dulos (tests e simples) se encontram fora da pasta docs, ent\u00e3o para eles serem reconhecidos \u00e9 necess\u00e1rio especificar a sua localiza\u00e7\u00e3o.\n\n```python\nimport os\nimport sys\nsys.path.insert(0, os.path.abspath('.'))\nsys.path.insert(0, os.path.abspath('../simples'))\nsys.path.insert(0, os.path.abspath('../tests'))\n```\n* Para usar o template do _read the docs_ \u00e9 necess\u00e1rio realizar a instala\u00e7\u00e3o do tema e por fim alterar a vari\u00e1vel ``html_theme``.\n\nNo terminal:\n```console\nfoo@bar:~/ pip install sphinx_rtd_theme\n```\nNo arquivo ``conf.py``\n```python\nhtml_theme = 'sphinx_rtd_theme'\n```\n\n#### Modificando o ``index.rst``\n\nNo arquivo ``index.rst`` adicionar a seguinte linha ``source/modules``\n\n```\n .. toctree::\n :maxdepth: 2\n :caption: Contents:\n\n source/modules\n```\n\nPor fim, para construir o html da sua documenta\u00e7\u00e3o, execute o terminal o comando ``make html``\n\n```console\nfoo@bar:~/simples/docs$ make html\n```\n\nO html ser\u00e1 gerado dentro do caminho ``~/simples/docs/_build/html``. Voc\u00ea poder\u00e1 visualizar a aplica\u00e7\u00e3o em ```http://localhost:8000/```, realizando os seguintes comandos.\n\n```console\nfoo@bar:~/simples/docs$ cd _build/html\nfoo@bar:~/simples/docs/_build/html$ python -m http.server\nServing HTTP on 0.0.0.0 port 8000 (http://0.0.0.0:8000/) ...\n```\n\n#### Refer\u00eancias\n\n* [Sphinx for Python documentation ](https://gisellezeno.com/tutorials/sphinx-for-python-documentation.html)\n* [First Steps with Sphinx](https://www.sphinx-doc.org/en/1.5/tutorial.html)\n* [Getting Started with Sphinx](https://docs.readthedocs.io/en/stable/intro/getting-started-with-sphinx.html)\n\n\n\n", "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/jecamanga/simples", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "simples", "package_url": "https://pypi.org/project/simples/", "platform": "", "project_url": "https://pypi.org/project/simples/", "project_urls": { "Homepage": "https://github.com/jecamanga/simples" }, "release_url": "https://pypi.org/project/simples/0.1.0a0/", "requires_dist": null, "requires_python": "", "summary": "Soma dois n\u00fameros.", "version": "0.1.0a0" }, "last_serial": 5369375, "releases": { "0.1.0a0": [ { "comment_text": "", "digests": { "md5": "a4c5c3caca05727b8ab12645d00d3461", "sha256": "e86057df5e596679d99cdb6fe922ec02e8ee39bc076b7b1a01c59853c7f627e5" }, "downloads": -1, "filename": "simples-0.1.0a0-py3-none-any.whl", "has_sig": false, "md5_digest": "a4c5c3caca05727b8ab12645d00d3461", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 4568, "upload_time": "2019-06-06T22:33:38", "url": "https://files.pythonhosted.org/packages/c0/6d/3ffb2daf03ae34dbdcbb2f62753f0db5c371df08210d5ab263a0444a6883/simples-0.1.0a0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "124534759dc31cd70c44f0ab1c08e0f7", "sha256": "103cf4618802d9d5675c8fd145aa63a603a67f2b77f16122f284df354cd5aa7f" }, "downloads": -1, "filename": "simples-0.1.0a0.tar.gz", "has_sig": false, "md5_digest": "124534759dc31cd70c44f0ab1c08e0f7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3312, "upload_time": "2019-06-06T22:33:41", "url": "https://files.pythonhosted.org/packages/88/4f/4fc56cd73800d0fb4a9263ab317d742598134fefd0e8ddbc20eb0375a8f7/simples-0.1.0a0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "a4c5c3caca05727b8ab12645d00d3461", "sha256": "e86057df5e596679d99cdb6fe922ec02e8ee39bc076b7b1a01c59853c7f627e5" }, "downloads": -1, "filename": "simples-0.1.0a0-py3-none-any.whl", "has_sig": false, "md5_digest": "a4c5c3caca05727b8ab12645d00d3461", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 4568, "upload_time": "2019-06-06T22:33:38", "url": "https://files.pythonhosted.org/packages/c0/6d/3ffb2daf03ae34dbdcbb2f62753f0db5c371df08210d5ab263a0444a6883/simples-0.1.0a0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "124534759dc31cd70c44f0ab1c08e0f7", "sha256": "103cf4618802d9d5675c8fd145aa63a603a67f2b77f16122f284df354cd5aa7f" }, "downloads": -1, "filename": "simples-0.1.0a0.tar.gz", "has_sig": false, "md5_digest": "124534759dc31cd70c44f0ab1c08e0f7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3312, "upload_time": "2019-06-06T22:33:41", "url": "https://files.pythonhosted.org/packages/88/4f/4fc56cd73800d0fb4a9263ab317d742598134fefd0e8ddbc20eb0375a8f7/simples-0.1.0a0.tar.gz" } ] }