pyquickhelper


Namepyquickhelper JSON
Version 1.12.3823 PyPI version JSON
download
home_pagehttp://www.xavierdupre.fr/app/pyquickhelper/helpsphinx/index.html
SummaryVarious functionalities: folder synchronization, simple logging function, helpers to generate documentation with sphinx, sphinx extension, to run a command line, to run a notebook...
upload_time2023-05-31 10:38:14
maintainer
docs_urlNone
authorXavier Dupré
requires_python
licenseMIT
keywords pyquickhelper synchronization files documentation xavier dupré sphinx notebooks rst helpers automation
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI
coveralls test coverage No coveralls.
            
.. image:: https://github.com/sdpython/pyquickhelper/blob/master/_doc/sphinxdoc/source/_static/project_ico.png?raw=true
    :target: https://github.com/sdpython/pyquickhelper/

.. _l-README:

pyquickhelper: automation of many things
========================================

.. image:: https://travis-ci.com/sdpython/pyquickhelper.svg?branch=master
    :target: https://app.travis-ci.com/github/sdpython/pyquickhelper/
    :alt: Build status

.. image:: https://ci.appveyor.com/api/projects/status/t2g9olcgqgdvqq3l?svg=true
    :target: https://ci.appveyor.com/project/sdpython/pyquickhelper
    :alt: Build Status Windows

.. image:: https://circleci.com/gh/sdpython/pyquickhelper/tree/master.svg?style=svg
    :target: https://circleci.com/gh/sdpython/pyquickhelper/tree/master

.. image:: https://dev.azure.com/xavierdupre3/pyquickhelper/_apis/build/status/sdpython.pyquickhelper
    :target: https://dev.azure.com/xavierdupre3/pyquickhelper/

.. image:: https://badge.fury.io/py/pyquickhelper.svg
    :target: https://pypi.org/project/pyquickhelper/

.. image:: https://img.shields.io/badge/license-MIT-blue.svg
    :alt: MIT License
    :target: http://opensource.org/licenses/MIT

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

.. image:: http://img.shields.io/github/issues/sdpython/pyquickhelper.png
    :alt: GitHub Issues
    :target: https://github.com/sdpython/pyquickhelper/issues

.. image:: https://app.codacy.com/project/badge/Grade/9d73a6712fb24e2fa404b3e33c6201ac
    :target: https://www.codacy.com/gh/sdpython/pyquickhelper/dashboard?utm_source=github.com&utm_medium=referral&utm_content=sdpython/pyquickhelper&utm_campaign=Badge_Grade
    :alt: Codacy Badge

.. image:: http://www.xavierdupre.fr/app/pyquickhelper/helpsphinx/_images/nbcov.png
    :target: http://www.xavierdupre.fr/app/pyquickhelper/helpsphinx/all_notebooks_coverage.html
    :alt: Notebook Coverage

.. image:: https://pepy.tech/badge/pyquickhelper/month
    :target: https://pepy.tech/project/pyquickhelper/month
    :alt: Downloads

.. image:: https://img.shields.io/github/forks/sdpython/pyquickhelper.svg
    :target: https://github.com/sdpython/pyquickhelper/
    :alt: Forks

.. image:: https://img.shields.io/github/stars/sdpython/pyquickhelper.svg
    :target: https://github.com/sdpython/pyquickhelper/
    :alt: Stars

.. image:: https://img.shields.io/github/repo-size/sdpython/pyquickhelper
    :target: https://github.com/sdpython/pyquickhelper/
    :alt: size

`pyquickhelper <http://www.xavierdupre.fr/app/pyquickhelper/helpsphinx/index.html>`_
is used to automate the release of the documentation such as automating *Jenkins*,
converting notebooks into many formats, extending *Sphinx* with custom
extensions... It assumes the project is organized on the same template
as this one.

Functionalities
---------------

* simple forms in notebooks
* help generation including notebook conversion
* folder synchronization
* logging
* help running unit tests
* simple server to server sphinx documentation
* file compression, zip, gzip, 7z
* helpers for ipython notebooks (upgrade, offline run)
* parser to quickly add a magic command in a notebook
* Sphinx directives to integrate a blogpost in the documentation
* mechanism to add forms in notebooks

Design
------

This project contains the following folders:

* a source folder: *src*
* a unit test folder: *_unittests*, go to this folder and run *run_unittests.py*
* a folder: *_doc*, it will contain the documentation, a subfolder *_doc/sphinxdox/source/blog* contains blog post
  to communicate on the module
* a file *setup.py* to build and to install the module, if the source were retrieve from GitHub,
  the script can also be called with the following extra options (*python setup.py <option>*):
  * clean_space: remove extra spaces in the code
  * build_sphinx: builds the documentation
  * unittests: run the unit tests, compute the code coverage
* a script *build_script.bat* which produces many script on Windows to easily run the setup,
  generate the documentation, run the unit tests.

Examples
--------

Convert a notebook into slides:

::

    from pyquickhelper.helpgen import nb2slides
    nb2slides("nb.ipynb", "convert.slides.html")

Merge two notebooks:

::

    from pyquickhelper.ipythonhelper import read_nb
    nb1 = read_nb("<file1>", kernel=False)
    nb2 = read_nb("<file2>", kernel=False)
    nb1.merge_notebook(nb2)
    nb1.to_json(outfile)

Run a notebook:

::

    from pyquickhelper.ipythonhelper import run_notebook
    run_notebook("source.ipynb", working_dir="temp",
                outfilename="modified.ipynb",
                additional_path = [ "c:/temp/mymodule/src" ] )

Run a command line program:

::

    from pyquickhelper.loghelper import run_cmd
    out,err = run_cmd("python setup.py install", wait=True)

A sphinx extension to generate python documentation from a script:

::

    .. runpython::
        :showcode:

        import sys
        print("sys.version_info=", str(sys.version_info))

Links
-----

* `GitHub/pyquickhelper <https://github.com/sdpython/pyquickhelper>`_
* `documentation <http://www.xavierdupre.fr/app/pyquickhelper/helpsphinx/index.html>`_
* `Blog <http://www.xavierdupre.fr/app/pyquickhelper/helpsphinx/blog/main_0000.html#ap-main-0>`_

.. image:: https://mybinder.org/badge_logo.svg
    :target: https://mybinder.org/v2/gh/sdpython/pyquickhelper/master
    :alt: Binder

            

Raw data

            {
    "_id": null,
    "home_page": "http://www.xavierdupre.fr/app/pyquickhelper/helpsphinx/index.html",
    "name": "pyquickhelper",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "pyquickhelper,synchronization, files,documentation,Xavier Dupr\u00e9,sphinx,notebooks,rst,helpers,automation",
    "author": "Xavier Dupr\u00e9",
    "author_email": "xavier.dupre@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/b4/5e/019b51cd63151d249e75b68b144a7153537a606d9dd9b93e9077aa9ec762/pyquickhelper-1.12.3823.tar.gz",
    "platform": null,
    "description": "\n.. image:: https://github.com/sdpython/pyquickhelper/blob/master/_doc/sphinxdoc/source/_static/project_ico.png?raw=true\n    :target: https://github.com/sdpython/pyquickhelper/\n\n.. _l-README:\n\npyquickhelper: automation of many things\n========================================\n\n.. image:: https://travis-ci.com/sdpython/pyquickhelper.svg?branch=master\n    :target: https://app.travis-ci.com/github/sdpython/pyquickhelper/\n    :alt: Build status\n\n.. image:: https://ci.appveyor.com/api/projects/status/t2g9olcgqgdvqq3l?svg=true\n    :target: https://ci.appveyor.com/project/sdpython/pyquickhelper\n    :alt: Build Status Windows\n\n.. image:: https://circleci.com/gh/sdpython/pyquickhelper/tree/master.svg?style=svg\n    :target: https://circleci.com/gh/sdpython/pyquickhelper/tree/master\n\n.. image:: https://dev.azure.com/xavierdupre3/pyquickhelper/_apis/build/status/sdpython.pyquickhelper\n    :target: https://dev.azure.com/xavierdupre3/pyquickhelper/\n\n.. image:: https://badge.fury.io/py/pyquickhelper.svg\n    :target: https://pypi.org/project/pyquickhelper/\n\n.. image:: https://img.shields.io/badge/license-MIT-blue.svg\n    :alt: MIT License\n    :target: http://opensource.org/licenses/MIT\n\n.. image:: https://codecov.io/github/sdpython/pyquickhelper/coverage.svg?branch=master\n    :target: https://codecov.io/github/sdpython/pyquickhelper?branch=master\n\n.. image:: http://img.shields.io/github/issues/sdpython/pyquickhelper.png\n    :alt: GitHub Issues\n    :target: https://github.com/sdpython/pyquickhelper/issues\n\n.. image:: https://app.codacy.com/project/badge/Grade/9d73a6712fb24e2fa404b3e33c6201ac\n    :target: https://www.codacy.com/gh/sdpython/pyquickhelper/dashboard?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=sdpython/pyquickhelper&amp;utm_campaign=Badge_Grade\n    :alt: Codacy Badge\n\n.. image:: http://www.xavierdupre.fr/app/pyquickhelper/helpsphinx/_images/nbcov.png\n    :target: http://www.xavierdupre.fr/app/pyquickhelper/helpsphinx/all_notebooks_coverage.html\n    :alt: Notebook Coverage\n\n.. image:: https://pepy.tech/badge/pyquickhelper/month\n    :target: https://pepy.tech/project/pyquickhelper/month\n    :alt: Downloads\n\n.. image:: https://img.shields.io/github/forks/sdpython/pyquickhelper.svg\n    :target: https://github.com/sdpython/pyquickhelper/\n    :alt: Forks\n\n.. image:: https://img.shields.io/github/stars/sdpython/pyquickhelper.svg\n    :target: https://github.com/sdpython/pyquickhelper/\n    :alt: Stars\n\n.. image:: https://img.shields.io/github/repo-size/sdpython/pyquickhelper\n    :target: https://github.com/sdpython/pyquickhelper/\n    :alt: size\n\n`pyquickhelper <http://www.xavierdupre.fr/app/pyquickhelper/helpsphinx/index.html>`_\nis used to automate the release of the documentation such as automating *Jenkins*,\nconverting notebooks into many formats, extending *Sphinx* with custom\nextensions... It assumes the project is organized on the same template\nas this one.\n\nFunctionalities\n---------------\n\n* simple forms in notebooks\n* help generation including notebook conversion\n* folder synchronization\n* logging\n* help running unit tests\n* simple server to server sphinx documentation\n* file compression, zip, gzip, 7z\n* helpers for ipython notebooks (upgrade, offline run)\n* parser to quickly add a magic command in a notebook\n* Sphinx directives to integrate a blogpost in the documentation\n* mechanism to add forms in notebooks\n\nDesign\n------\n\nThis project contains the following folders:\n\n* a source folder: *src*\n* a unit test folder: *_unittests*, go to this folder and run *run_unittests.py*\n* a folder: *_doc*, it will contain the documentation, a subfolder *_doc/sphinxdox/source/blog* contains blog post\n  to communicate on the module\n* a file *setup.py* to build and to install the module, if the source were retrieve from GitHub,\n  the script can also be called with the following extra options (*python setup.py <option>*):\n  * clean_space: remove extra spaces in the code\n  * build_sphinx: builds the documentation\n  * unittests: run the unit tests, compute the code coverage\n* a script *build_script.bat* which produces many script on Windows to easily run the setup,\n  generate the documentation, run the unit tests.\n\nExamples\n--------\n\nConvert a notebook into slides:\n\n::\n\n    from pyquickhelper.helpgen import nb2slides\n    nb2slides(\"nb.ipynb\", \"convert.slides.html\")\n\nMerge two notebooks:\n\n::\n\n    from pyquickhelper.ipythonhelper import read_nb\n    nb1 = read_nb(\"<file1>\", kernel=False)\n    nb2 = read_nb(\"<file2>\", kernel=False)\n    nb1.merge_notebook(nb2)\n    nb1.to_json(outfile)\n\nRun a notebook:\n\n::\n\n    from pyquickhelper.ipythonhelper import run_notebook\n    run_notebook(\"source.ipynb\", working_dir=\"temp\",\n                outfilename=\"modified.ipynb\",\n                additional_path = [ \"c:/temp/mymodule/src\" ] )\n\nRun a command line program:\n\n::\n\n    from pyquickhelper.loghelper import run_cmd\n    out,err = run_cmd(\"python setup.py install\", wait=True)\n\nA sphinx extension to generate python documentation from a script:\n\n::\n\n    .. runpython::\n        :showcode:\n\n        import sys\n        print(\"sys.version_info=\", str(sys.version_info))\n\nLinks\n-----\n\n* `GitHub/pyquickhelper <https://github.com/sdpython/pyquickhelper>`_\n* `documentation <http://www.xavierdupre.fr/app/pyquickhelper/helpsphinx/index.html>`_\n* `Blog <http://www.xavierdupre.fr/app/pyquickhelper/helpsphinx/blog/main_0000.html#ap-main-0>`_\n\n.. image:: https://mybinder.org/badge_logo.svg\n    :target: https://mybinder.org/v2/gh/sdpython/pyquickhelper/master\n    :alt: Binder\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Various functionalities: folder synchronization, simple logging function, helpers to generate documentation with sphinx, sphinx extension, to run a command line, to run a notebook...",
    "version": "1.12.3823",
    "project_urls": {
        "Download": "https://github.com/sdpython/pyquickhelper",
        "Homepage": "http://www.xavierdupre.fr/app/pyquickhelper/helpsphinx/index.html"
    },
    "split_keywords": [
        "pyquickhelper",
        "synchronization",
        " files",
        "documentation",
        "xavier dupr\u00e9",
        "sphinx",
        "notebooks",
        "rst",
        "helpers",
        "automation"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "3bff8ab2eb97c228b1877fc0a6317b20c6cc2bab5a166e70d500fff823c907a1",
                "md5": "f8367425df7a04f5999cd88946acd210",
                "sha256": "a183c0c2202198387be79810396f282d07ecc2ecf77b95a17a3dbac12dd3c326"
            },
            "downloads": -1,
            "filename": "pyquickhelper-1.12.3823-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "f8367425df7a04f5999cd88946acd210",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 3281007,
            "upload_time": "2023-05-31T10:38:10",
            "upload_time_iso_8601": "2023-05-31T10:38:10.761683Z",
            "url": "https://files.pythonhosted.org/packages/3b/ff/8ab2eb97c228b1877fc0a6317b20c6cc2bab5a166e70d500fff823c907a1/pyquickhelper-1.12.3823-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "b45e019b51cd63151d249e75b68b144a7153537a606d9dd9b93e9077aa9ec762",
                "md5": "87475a4fabdb56a585f85df10e07765f",
                "sha256": "db2bdf4f27542aa2097d3ce74908e8612b7ea2e40aa46b61863b293c33e9bc35"
            },
            "downloads": -1,
            "filename": "pyquickhelper-1.12.3823.tar.gz",
            "has_sig": false,
            "md5_digest": "87475a4fabdb56a585f85df10e07765f",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 3135979,
            "upload_time": "2023-05-31T10:38:14",
            "upload_time_iso_8601": "2023-05-31T10:38:14.994090Z",
            "url": "https://files.pythonhosted.org/packages/b4/5e/019b51cd63151d249e75b68b144a7153537a606d9dd9b93e9077aa9ec762/pyquickhelper-1.12.3823.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-05-31 10:38:14",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "sdpython",
    "github_project": "pyquickhelper",
    "travis_ci": true,
    "coveralls": false,
    "github_actions": false,
    "circle": true,
    "landscape": true,
    "appveyor": true,
    "requirements": [],
    "lcname": "pyquickhelper"
}
        
Elapsed time: 0.15271s