Skip to content
Permalink
Browse files

requirements, documentation

  • Loading branch information...
sdpython committed Feb 23, 2018
1 parent 0c1886e commit c369f590cad3fea1bce97a707f75980623d4e921
Showing with 49 additions and 77 deletions.
  1. +23 −25 README.rst
  2. +1 −42 requirements.txt
  3. +25 −10 setup.py
@@ -4,39 +4,37 @@
README
======

.. only:: html
.. image:: https://travis-ci.org/sdpython/python3_module_template.svg?branch=master
:target: https://travis-ci.org/sdpython/python3_module_template
:alt: Build status

.. image:: https://travis-ci.org/sdpython/python3_module_template.svg?branch=master
:target: https://travis-ci.org/sdpython/python3_module_template
:alt: Build status
.. image:: https://ci.appveyor.com/api/projects/status/8yv4brsckay4374a?svg=true
:target: https://ci.appveyor.com/project/sdpython/python3-module-template
:alt: Build Status Windows

.. image:: https://ci.appveyor.com/api/projects/status/8yv4brsckay4374a?svg=true
:target: https://ci.appveyor.com/project/sdpython/python3-module-template
:alt: Build Status Windows
.. image:: https://circleci.com/gh/sdpython/python3_module_template/tree/master.svg?style=svg
:target: https://circleci.com/gh/sdpython/python3_module_template/tree/master

.. image:: https://circleci.com/gh/sdpython/python3_module_template/tree/master.svg?style=svg
:target: https://circleci.com/gh/sdpython/python3_module_template/tree/master
.. image:: https://badge.fury.io/py/project_name.svg
:target: http://badge.fury.io/py/project_name

.. image:: https://badge.fury.io/py/project_name.svg
:target: http://badge.fury.io/py/project_name
.. image:: http://img.shields.io/github/issues/sdpython/python3_module_template.png
:alt: GitHub Issues
:target: https://github.com/sdpython/python3_module_template/issues

.. image:: http://img.shields.io/github/issues/sdpython/python3_module_template.png
:alt: GitHub Issues
:target: https://github.com/sdpython/python3_module_template/issues
.. image:: https://img.shields.io/badge/license-MIT-blue.svg
:alt: MIT License
:target: http://opensource.org/licenses/MIT

.. image:: https://img.shields.io/badge/license-MIT-blue.svg
:alt: MIT License
:target: http://opensource.org/licenses/MIT
.. image:: https://coveralls.io/repos/sdpython/python3_module_template/badge.svg?branch=master&service=github
:target: https://coveralls.io/github/sdpython/python3_module_template?branch=master

.. image:: https://coveralls.io/repos/sdpython/python3_module_template/badge.svg?branch=master&service=github
:target: https://coveralls.io/github/sdpython/python3_module_template?branch=master
.. image:: https://requires.io/github/sdpython/python3_module_template/requirements.svg?branch=master
:target: https://requires.io/github/sdpython/python3_module_template/requirements/?branch=master
:alt: Requirements Status

.. image:: https://requires.io/github/sdpython/python3_module_template/requirements.svg?branch=master
:target: https://requires.io/github/sdpython/python3_module_template/requirements/?branch=master
:alt: Requirements Status

.. image:: https://codecov.io/github/sdpython/python3_module_template/coverage.svg?branch=master
:target: https://codecov.io/github/sdpython/python3_module_template?branch=master
.. image:: https://codecov.io/github/sdpython/python3_module_template/coverage.svg?branch=master
:target: https://codecov.io/github/sdpython/python3_module_template?branch=master

.. image:: http://www.xavierdupre.fr/app/python3_module_template/helpsphinx/_images/nbcov.png
:target: http://www.xavierdupre.fr/app/python3_module_template/helpsphinx/all_notebooks_coverage.html
@@ -1,45 +1,4 @@
autopep8
babel!=2.0
bokeh
coverage
docformatter
ipython>=5.0.0
jupyter
jupyter-client
jupyter_sphinx
jyquickhelper
keyring
Mako
matplotlib
mistune
nbconvert>=5.0.0
nbformat
nbpresent
nbsphinx
notebook>=5.0.0
numpy>=1.11.1
openpyxl
pandas>=0.20.0
pandocfilters
pillow
pycodestyle>=2.0.0
pycryptodomex
pydocstyle
pyflakes
pylzma
pyquickhelper>=1.5.2122
python-jenkins
PyYAML
semantic_version
setuptools
Sphinx
sphinx-gallery
sphinx-rtd-theme
sphinxcontrib-images
sphinxcontrib-imagesvg
sphinxcontrib-jsdemo
sphinxjp.themes.sphinxjp
tqdm
unify
virtualenv
pyquickhelper>=1.7.2438
wheel
@@ -49,8 +49,26 @@ def is_local():
file = os.path.abspath(__file__).replace("\\", "/").lower()
if "/temp/" in file and "pip-" in file:
return False
from pyquickhelper.pycode.setup_helper import available_commands_list
return available_commands_list(sys.argv)
for cname in {"bdist_msi", "build27", "build_script", "build_sphinx", "build_ext",
"bdist_wheel", "bdist_egg", "bdist_wininst", "clean_pyd", "clean_space",
"copy27", "copy_dist", "local_pypi", "notebook", "publish", "publish_doc",
"register", "unittests", "unittests_LONG", "unittests_SKIP", "unittests_GUI",
"run27", "sdist", "setupdep", "test_local_pypi", "upload_docs", "setup_hook",
"copy_sphinx", "write_version"}:
if cname in sys.argv:
try:
import_pyquickhelper()
except ImportError:
return False
return True
else:
return False

return False


def ask_help():
return "--help" in sys.argv or "--help-commands" in sys.argv


def verbose():
@@ -66,7 +84,7 @@ def verbose():
##########


if is_local() and "--help" not in sys.argv and "--help-commands" not in sys.argv:
if is_local() and not ask_help():
def write_version():
from pyquickhelper.pycode import write_version_for_setup
return write_version_for_setup(__file__)
@@ -87,13 +105,8 @@ def write_version():
# when the module is installed, no commit number is displayed
subversion = ""

if "upload" in sys.argv and not subversion:
if "upload" in sys.argv and not subversion and not ask_help():
# avoid uploading with a wrong subversion number
try:
import pyquickhelper
pyq = True
except ImportError:
pyq = False
raise Exception(
"subversion is empty, cannot upload, is_local()={0}, pyquickhelper={1}".format(is_local(), pyq))

@@ -120,8 +133,8 @@ def write_version():
if is_local():
from pyquickhelper import get_fLOG
logging_function = get_fLOG()
from pyquickhelper.pycode import process_standard_options_for_setup
logging_function(OutputPrint=True)
from pyquickhelper.pycode import process_standard_options_for_setup
r = process_standard_options_for_setup(
sys.argv, __file__, project_var_name,
extra_ext=["tohelp"],
@@ -142,6 +155,8 @@ def write_version():
if len(sys.argv) in (1, 2) and sys.argv[-1] in ("--help-commands",):
from pyquickhelper.pycode import process_standard_options_for_setup_help
process_standard_options_for_setup_help(sys.argv)
from pyquickhelper.pycode import clean_readme
long_description = clean_readme(long_description)

setup(
name=project_var_name,

0 comments on commit c369f59

Please sign in to comment.
You can’t perform that action at this time.