# -*- coding: utf-8 -*-
from setuptools import setup

packages = \
['click_loguru']

package_data = \
{'': ['*']}

install_requires = \
['attrs>=19.3,<21.0',
 'click>=7.1.2,<8.0.0',
 'loguru>=0.5.0,<0.6.0',
 'memory_profiler>=0.57.0,<0.58.0']

setup_kwargs = {
    'name': 'click-loguru',
    'version': '1.3.0',
    'description': 'Logging to stderr and file for click applications.',
    'long_description': 'click_loguru\n============\n``click_loguru`` initializes `click <https://click.palletsprojects.com/>`_ CLI-based\nprograms for logging to stderr and (optionally) a log file via the\n`loguru <https://github.com/Delgan/loguru/>`_ logger.  It can optionally log run time,\nCPU use, and peak memory use of user functions.\n\nLog file names will include the name of your program and (if your application uses\nsubcommands via ``@click.group()``), the name of the subcommand. Log files are \n(optionally) numbered, with a retention policy specified.  Log files can be\nenabled or disabled per-subcommand and written to a subdirectory that your\napplication specifies.  \n\nGlobal CLI options control verbose/quiet levels and log file creation.\nThe values of these global options are accessible, along with the path to the\nlog file, from your application.\n\nInstantiation\n-------------\n``click_loguru`` objects are instantiated from the ``ClickLoguru`` class as::\n\n      click_loguru = ClickLoguru(name,\n                                 version,\n                                 retention=4,\n                                 stderr_format_func=None,\n                                 log_dir_parent="./logs",\n                                 file_log_level="DEBUG",\n                                 stderr_log_level="INFO",\n                                 timer_log_level="debug",\n        )\n\nwhere:\n\n* **name** is the name of your application\n* **version** is the version string of your application\n* **retention** is the log file retention policy.  If set to a non-zero value, the\n  log files will be given by ``logs/NAME[-SUBCOMMAND]_n.log`` where ```NAME`` is the name\n  of your application, ``SUBCOMMAND`` is the group subcommand (if you are using\n  click groups), and ``n`` is an integer number.  The value of ``retention`` specifies\n  the number of log files to be kept.\n* **stderr_format_func** is the format function to be used for messages to stderr, as\n  defined by ``loguru``.  Default is very short, with ``INFO``-level messages having\n  no level name printed.\n* **log_dir_parent** sets the location of the log file directory.  This value may be\n  overridden per-command.\n* **file_log_level**  sets the level of logging to the log file.\n* **stderr_log_level** sets the level of logging to stderr.  This value may be overridden\n  by the ``--quiet`` or ``--verbose`` options.\n* **timer_log_level** is the level at which ``elapsed_time`` results will be logged.\n\n\nMethods\n-------\nThe ``ClickLoguru`` class defines the following methods:\n\n* **logging_options** is a decorator to be used for your application\'s CLI function.  This\n  decorator defines the global options that allows control of ``quiet``, ``verbose``,\n  and ``log file`` booleans.\n\n* **stash_subcommand** is a  decorator to be used for the CLI method for applications\n  which define subcommands.\n\n* **init_logger** is  a decorator which must be used for each subcommand.   It allows\n  override of the default ``log_dir_parent`` established at instantiation,\n  as well as turning off file logging for that command by setting ``log file`` to ``False``.\n\n* **log_elapsed_time** is a decorator which causes the elapsed wall-clock time and\n  CPU time in seconds for the (sub)command\n  to be emitted at the level specified by the ``level=`` argument (``debug`` by default).\n\n* **get_global_options** is a method that returns the context object associated with the\n  global options. The context object is printable.  The attributes of the context object are the booleans ``verbose``,\n  ``quiet``, and ``log file``, the string ``subcommand`` showing the subcommand that was invoked,\n  and ``log file_handler_id`` if your code wishes to manipulate the handler directly.\n\n* **user_global_options_callback** is a method to be used as\n  a callback when your code declares a global option.  Values\n  of these global options will be stored in a user global\n  options context dictionary.\n\n* **get_user_global_options** is a method to retrieve a\n  dictionary of values of user global options.\n\n* **elapsed_timer** is a method that accepts a single argument, ``phase``.\n  The next invocation of this method will produce a log entry at ``timer_log_level``\n  showing the elapsed wall clock and CPU time.  If ``phase`` is ``None``, \n  the next invocation will not produce a message.\n\n* **log_peak_memory_use** is a method that results in the peak memory usage for\n  the function and children of the function to be emitted at a level specified\n  by the ``level=`` keyword (``debug`` is default).  This functionality\n  is somewhat expensive in that it requires an additional thread, so the global\n  option ``--profile_mem`` must be enabled.\n\n\nSee the `simple test CLI application\n<https://github.com/legumeinfo/click_loguru/blob/master/tests/__init__.py>`_\nfor usage examples.\n\nPrerequisites\n-------------\nPython 3.6 or greater is required.\nThis package is tested under Linux using Python 3.8.  This package has\nno dependencies beyond``click`` and ``loguru`` themselves.\n\n\nProject Status\n--------------\n+-------------------+------------+\n| Latest Release    | |pypi|     |\n+-------------------+------------+\n| Activity          | |repo|     |\n+-------------------+------------+\n| Downloads         ||downloads| |\n+-------------------+------------+\n| Download Rate     | |dlrate|   |\n+-------------------+------------+\n| License           | |license|  |\n+-------------------+------------+\n| Travis Build      | |travis|   |\n+-------------------+------------+\n| Coverage          | |coverage| |\n+-------------------+------------+\n| Code Grade        | |codacy|   |\n+-------------------+------------+\n| Dependencies      | |depend|   |\n+-------------------+------------+\n| Issues            | |issues|   |\n+-------------------+------------+\n| Code Style        | |black|    |\n+-------------------+------------+\n| Pre-commit        | |precommit||\n+-------------------+------------+\n\n.. |pypi| image:: https://img.shields.io/pypi/v/click_loguru.svg\n    :target: https://pypi.python.org/pypi/click_loguru\n    :alt: Python package\n\n.. |repo| image:: https://img.shields.io/github/last-commit/legumeinfo/click_loguru\n    :target: https://github.com/legumeinfo/click_loguru\n    :alt: GitHub repository\n\n.. |license| image:: https://img.shields.io/badge/License-BSD%203--Clause-blue.svg\n    :target: https://github.com/legumeinfo/click_loguru/blob/master/LICENSE.txt\n    :alt: License terms\n\n.. |travis| image:: https://img.shields.io/travis/legumeinfo/click_loguru.svg\n    :target:  https://travis-ci.org/legumeinfo/click_loguru\n    :alt: Travis CI\n\n.. |codacy| image:: https://api.codacy.com/project/badge/Grade/6ee5771afe014cffbb32a2f79cf17fff\n    :target: https://www.codacy.com/gh/legumeinfo/click_loguru?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=legumeinfo/click_loguru&amp;utm_campaign=Badge_Grade\n    :alt: Codacy.io grade\n\n.. |coverage| image:: https://codecov.io/gh/legumeinfo/click_loguru/branch/master/graph/badge.svg\n    :target: https://codecov.io/gh/legumeinfo/click_loguru\n    :alt: Codecov.io test coverage\n\n.. |black| image:: https://img.shields.io/badge/code%20style-black-000000.svg?style=flat-square\n    :target: https://github.com/psf/black\n    :alt: Black is the uncompromising Python code formatter\n\n.. |precommit| image:: https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white\n    :target: https://github.com/pre-commit/pre-commit\n    :alt: pre-commit\n\n.. |issues| image:: https://img.shields.io/github/issues/legumeinfo/click_loguru.svg\n    :target:  https://github.com/legumeinfo/click_loguru/issues\n    :alt: Issues reported\n\n\n.. |depend| image:: https://api.dependabot.com/badges/status?host=github&repo=legumeinfo/click_loguru\n     :target: https://app.dependabot.com/accounts/legumeinfo/repos/236847525\n     :alt: dependabot dependencies\n\n\n.. |dlrate| image:: https://img.shields.io/pypi/dm/click_loguru\n    :target: https://pypistats.org/packages/click_loguru\n    :alt: Download stats\n\n.. |downloads| image:: https://pepy.tech/badge/click_loguru\n    :target: https://pepy.tech/project/click_loguru\n    :alt: Download stats\n',
    'author': 'Joel Berendzen',
    'author_email': 'joelb@ncgr.org',
    'maintainer': None,
    'maintainer_email': None,
    'url': 'https://github.com/legumeinfo/click_loguru',
    'packages': packages,
    'package_data': package_data,
    'install_requires': install_requires,
    'python_requires': '>=3.6.1,<4.0.0',
}


setup(**setup_kwargs)
