Merge pull request #1120 from pallets/meta
Before adoption: this commit came in with the history the project adopted, so no landing records it.
update metadata
authored by David Lord · committed by GitHub · parents a589835, e8bf968 · Browse files · 18 files·+189 added−189 removed
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Diff stats
18 files+189 added−189 removed
- other:+189 added−189 removed
Provenance
- Commit
b4d25f8- Tree
58c41a4- Author
David Lord <davidism@gmail.com>- Committer
GitHub <noreply@github.com>- Parent 1
a589835- Parent 2
e8bf968
18 files changed+189 added−189 removed
modified:click/__init__.py+9 added-11 removed
1 # -*- coding: utf-8 -*-2 """3- click4- ~~~~~3+click4+~~~~~5 6- Click is a simple Python module that wraps the stdlib's optparse to make7- writing command line scripts fun. Unlike other modules, it's based around8- a simple API that does not come with too much magic and is composable.6+Click is a simple Python module inspired by the stdlib optparse to make7+writing command line scripts fun. Unlike other modules, it's based8+around a simple API that does not come with too much magic and is9+composable.10 10- In case optparse ever gets removed from the stdlib, it will be shipped by11- this module.12-13- :copyright: (c) 2014 by Armin Ronacher.14- :license: BSD, see LICENSE for more details.11+:copyright: © 2014 by the Pallets team.12+:license: BSD, see LICENSE.rst for more details.13 """14 15 # Core classes16 from .core import Context, BaseCommand, Command, MultiCommand, Group, \76 unmodified lines93 # literals.94 disable_unicode_literals_warning = False95 96 99-__version__ = '7.0-dev'97+__version__ = '7.0.dev'modified:click/_bashcomplete.py+6 added-2 removed
1-import collections1 import copy2 import os3 import re4 1 unmodified line6 from .parser import split_arg_string7 from .core import MultiCommand, Option, Argument8 from .types import Choice9 10+try:11+ from collections import abc12+except ImportError:13+ import collections as abc14+15 WORDBREAK = '='16 17 # Note, only BASH version 4.4 and later have the nosort option.18 COMPLETION_SCRIPT_BASH = '''143 unmodified lines162 if current_param_values is None:163 return True164 if cmd_param.nargs == -1:165 return True162- if isinstance(current_param_values, collections.Iterable) \166+ if isinstance(current_param_values, abc.Iterable) \167 and cmd_param.nargs > 1 and len(current_param_values) < cmd_param.nargs:168 return True169 return False170 123 unmodified linesmodified:click/_termui_impl.py+9 added-7 removed
1+# -*- coding: utf-8 -*-2 """2- click._termui_impl3- ~~~~~~~~~~~~~~~~~~3+click._termui_impl4+~~~~~~~~~~~~~~~~~~5 5- This module contains implementations for the termui module. To keep the6- import time of Click down, some infrequently used functionality is placed7- in this module and only imported as needed.6+This module contains implementations for the termui module. To keep the7+import time of Click down, some infrequently used functionality is8+placed in this module and only imported as needed.9 9- :copyright: (c) 2014 by Armin Ronacher.10- :license: BSD, see LICENSE for more details.10+:copyright: © 2014 by the Pallets team.11+:license: BSD, see LICENSE.rst for more details.12 """13+14 import os15 import sys16 import time17 import math604 unmodified linesmodified:click/parser.py+12 added-11 removed
1 # -*- coding: utf-8 -*-2 """3- click.parser4- ~~~~~~~~~~~~3+click.parser4+~~~~~~~~~~~~5 6- This module started out as largely a copy paste from the stdlib's7- optparse module with the features removed that we do not need from8- optparse because we implement them in Click on a higher level (for9- instance type handling, help formatting and a lot more).6+This module started out as largely a copy paste from the stdlib's7+optparse module with the features removed that we do not need from8+optparse because we implement them in Click on a higher level (for9+instance type handling, help formatting and a lot more).10 11- The plan is to remove more and more from here over time.11+The plan is to remove more and more from here over time.12 13- The reason this is a different module and not optparse from the stdlib14- is that there are differences in 2.x and 3.x about the error messages15- generated and optparse in the stdlib uses gettext for no good reason16- and might cause us issues.13+The reason this is a different module and not optparse from the stdlib14+is that there are differences in 2.x and 3.x about the error messages15+generated and optparse in the stdlib uses gettext for no good reason16+and might cause us issues.17 """18+19 import re20 from collections import deque21 from .exceptions import UsageError, NoSuchOption, BadOptionUsage, \22 BadArgumentUsage405 unmodified linesmodified:docs/license.rst+2 added-1 removed
8 unmodified lines9 10 License Text11 ------------12 13-.. include:: ../LICENSE13+.. include:: ../LICENSE.rst14+modified:docs/requirements.txt+1 added-1 removed
1-Sphinx~=1.7.71+Sphinx~=1.8.02 Pallets-Sphinx-Themes~=1.1.0modified:.appveyor.yml+3 added-3 removed
123456678891011128 unmodified lines212223242525262728environment: global: TOXENV: py,codecov
matrix: - PYTHON: C:\Python36-x64 - PYTHON: C:\Python37-x64 - PYTHON: C:\Python27-x64 - PYTHON: C:\Python36 - PYTHON: C:\Python37 - PYTHON: C:\Python27
init: - SET PATH=%PYTHON%;%PATH%8 unmodified lines
branches: only: - master - /^.*-maintenance$/ - /^.*\.x$/
cache: - '%LOCALAPPDATA%\pip\Cache'deleted:.coveragerc-3 removed
1-[run]2-branch = true3-source = click,testsmodified:.gitignore+15 added-12 removed
1-.DS_Store1 *.pyc2 *.pyo4-*.egg-ignore5-*.egg-info6-.pytest_cache7-dist8-build9-docs/_build10-click.egg-info11-venv/12-.tox13-.cache3+__pycache__/4+.idea/5 .ropeproject15-.idea6+.DS_Store7+env/8+venv/9+*.egg-info/10+*.eggs/11+build/12+dist/13+docs/_build/14+.pytest_cache/15+.tox/16+.coverage17+.coverage.*18+htmlcov/modified:.travis.yml+13 added-14 removed
1 os: linux2 sudo: false3 language: python4+python:5+ - "3.6"6+ - "3.5"7+ - "3.4"8+ - "2.7"9+ - "nightly"10+ - "pypy3"11+ - "pypy"12+env: TOXENV=py,codecov13 14 matrix:15 include:7- - python: 3.68- env: TOXENV=py,codecov9- - python: 3.510- env: TOXENV=py,codecov11- - python: 3.412- env: TOXENV=py,codecov13- - python: 2.714- env: TOXENV=py,codecov15- - python: pypy316- env: TOXENV=py,codecov17- - python: nightly18- env: TOXENV=py16+ - env: TOXENV=docs-html17 - os: osx18 language: generic19 env: TOXENV=py3,py2,codecov20 cache:1 unmodified line22 directories:23 - $HOME/Library/Caches/Homebrew24 - $HOME/Library/Caches/pip25 allow_failures:28- - python: pypy326 - python: nightly27+ - python: pypy328+ - python: pypy29 - os: osx30 fast_finish: true31 32 before_install:15 unmodified lines48 49 branches:50 only:51 - master53- - /^.*-maintenance/52+ - /^.*\.x$/53 54 notifications:55 email: falsedeleted:LICENSE-38 removed
1-Copyright (c) 2014 by Armin Ronacher.2-3-Click uses parts of optparse written by Gregory P. Ward and maintained by the4-Python software foundation. This is limited to code in the parser.py5-module:6-7-Copyright (c) 2001-2006 Gregory P. Ward. All rights reserved.8-Copyright (c) 2002-2006 Python Software Foundation. All rights reserved.9-10-Some rights reserved.11-12-Redistribution and use in source and binary forms, with or without13-modification, are permitted provided that the following conditions are14-met:15-16- * Redistributions of source code must retain the above copyright17- notice, this list of conditions and the following disclaimer.18-19- * Redistributions in binary form must reproduce the above20- copyright notice, this list of conditions and the following21- disclaimer in the documentation and/or other materials provided22- with the distribution.23-24- * The names of the contributors may not be used to endorse or25- promote products derived from this software without specific26- prior written permission.27-28-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS29-"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT30-LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR31-A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT32-OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,33-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT34-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,35-DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY36-THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT37-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE38-OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.added:LICENSE.rst+39 added
1+Copyright © 2014 by the Pallets team.2+3+Some rights reserved.4+5+Redistribution and use in source and binary forms of the software as6+well as documentation, with or without modification, are permitted7+provided that the following conditions are met:8+9+- Redistributions of source code must retain the above copyright10+ notice, this list of conditions and the following disclaimer.11+12+- Redistributions in binary form must reproduce the above copyright13+ notice, this list of conditions and the following disclaimer in the14+ documentation and/or other materials provided with the distribution.15+16+- Neither the name of the copyright holder nor the names of its17+ contributors may be used to endorse or promote products derived from18+ this software without specific prior written permission.19+20+THIS SOFTWARE AND DOCUMENTATION IS PROVIDED BY THE COPYRIGHT HOLDERS AND21+CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING,22+BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND23+FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE24+COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,25+INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT26+NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF27+USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON28+ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT29+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF30+THIS SOFTWARE AND DOCUMENTATION, EVEN IF ADVISED OF THE POSSIBILITY OF31+SUCH DAMAGE.32+33+----34+35+Click uses parts of optparse written by Gregory P. Ward and maintained36+by the Python Software Foundation. This is limited to code in parser.py.37+38+Copyright © 2001-2006 Gregory P. Ward. All rights reserved.39+Copyright © 2002-2006 Python Software Foundation. All rights reserved.deleted:Makefile-11 removed
1-test:2- @cd tests; PYTHONPATH=.. pytest --tb=short3-4-upload-docs:5- $(MAKE) -C docs dirhtml6- rsync -a docs/_build/dirhtml/* flow.srv.pocoo.org:/srv/websites/click.pocoo.org/static/7-8-release:9- python setup.py sdist bdist_wheel upload10-11-.PHONY: upload-docsmodified:MANIFEST.in+7 added-5 removed
1-include Makefile CHANGES LICENSE2-1+include CHANGES.rst2+include CONTRIBUTING.rst3+include LICENSE.rst4+include README.rst5+include tox.ini6 graft artwork4-graft tests5-graft examples7 graft docs8 prune docs/_build8-9+graft examples10+graft tests11 global-exclude *.py[co] .DS_Storemodified:README.rst+17 added-17 removed
1 \$ click\_2 ==========3 4 Click is a Python package for creating beautiful command line interfaces5-in a composable way with as little code as necessary. It's the "Command6-Line Interface Creation Kit". It's highly configurable but comes with5+in a composable way with as little code as necessary. It's the "Command6+Line Interface Creation Kit". It's highly configurable but comes with7 sensible defaults out of the box.8 9 It aims to make the process of writing command line tools quick and fun10 while also preventing any frustration caused by the inability to11 implement an intended CLI API.12 13 Click in three points:14 15-- arbitrary nesting of commands16-- automatic help page generation17-- supports lazy loading of subcommands at runtime15+- Arbitrary nesting of commands16+- Automatic help page generation17+- Supports lazy loading of subcommands at runtime18 19 20 Installing21 ----------18 unmodified lines40 41 import click42 43 @click.command()44- @click.option('--count', default=1, help='Number of greetings.')45- @click.option('--name', prompt='Your name',46- help='The person to greet.')44+ @click.option("--count", default=1, help="Number of greetings.")45+ @click.option("--name", prompt="Your name",46+ help="The person to greet.")47 def hello(count, name):48 """Simple program that greets NAME for a total of COUNT times."""49- for x in range(count):50- click.echo('Hello %s!' % name)49+ for _ in range(count):50+ click.echo("Hello, %s!" % name)51 52 if __name__ == '__main__':53 hello()54 1 unmodified line56 57 .. code-block:: text58 59 $ python hello.py --count=360- Your name: John61- Hello John!62- Hello John!63- Hello John!60+ Your name: Click61+ Hello, Click!62+ Hello, Click!63+ Hello, Click!64 65 66 Donate67 ------68 69-The Pallets organization develops and supports Flask and the libraries70-it uses. In order to grow the community of contributors and users, and69+The Pallets organization develops and supports Click and other popular70+packages. In order to grow the community of contributors and users, and71 allow the maintainers to devote more time to the projects, `please72 donate today`_.73 74 .. _please donate today: https://palletsprojects.com/donate3 unmodified lines78 -----79 80 * Website: https://palletsprojects.com/p/click/81 * Documentation: https://click.palletsprojects.com/82-* License: `BSD <https://github.com/pallets/click/blob/master/LICENSE>`_82+* License: `BSD <https://github.com/pallets/click/blob/master/LICENSE.rst>`_83 * Releases: https://pypi.org/project/click/84 * Code: https://github.com/pallets/click85 * Issue tracker: https://github.com/pallets/click/issues86 * Test status:5 unmodified linesmodified:setup.cfg+17 added-5 removed
1-[bdist_wheel]2-universal=13-1 [metadata]5-license_file = LICENSE2+license_file = LICENSE.rst3 4+[bdist_wheel]5+universal = 16+7 [tool:pytest]8-addopts = -p no:warnings --tb=short8+testpaths = tests9+10+[coverage:run]11+branch = True12+source =13+ click14+ tests15+16+[coverage:paths]17+source =18+ click19+ .tox/*/lib/python*/site-packages/click20+ .tox/pypy/site-packages/clickmodified:setup.py+31 added-44 removed
1-#!/usr/bin/env python2-# -*- coding: utf-8 -*-1 import io2 import re3 from setuptools import setup4 7-8-_version_re = re.compile(r'__version__\s+=\s+(.*)')9-10-11-with io.open('README.rst', 'rt', encoding='utf8') as f:5+with io.open("README.rst", "rt", encoding="utf8") as f:6 readme = f.read()7 14-with io.open('click/__init__.py', 'rt', encoding='utf8') as f:15- version = re.search(r'__version__ = \'(.*?)\'', f.read()).group(1)8+with io.open("click/__init__.py", "rt", encoding="utf8") as f:9+ version = re.search(r"__version__ = \'(.*?)\'", f.read()).group(1)10 11 setup(18- name='click',12+ name="Click",13 version=version,20- url='https://palletsprojects.com/p/click/',21- author='Armin Ronacher',22- author_email='armin.ronacher@active-4.com',23- maintainer='Pallets team',24- maintainer_email='contact@palletsprojects.com',25- long_description=readme,26- packages=['click'],27- description='A simple wrapper around optparse for '28- 'powerful command line utilities.',29- license='BSD',30- extras_require={31- 'dev': [32- 'pytest>=3',33- 'coverage',34- 'tox',35- 'sphinx',36- ],37- 'docs': [38- 'sphinx',39- 'Pallets-Sphinx-Themes',40- ]14+ url="https://palletsprojects.com/p/click/",15+ project_urls={16+ "Documentation": "https://click.palletsprojects.com/",17+ "Code": "https://github.com/pallets/click",18+ "Issue tracker": "https://github.com/pallets/click/issues",19 },20+ license="BSD",21+ author="Armin Ronacher",22+ author_email="armin.ronacher@active-4.com",23+ maintainer="Pallets Team",24+ maintainer_email="contact@palletsprojects.com",25+ description="Composable command line interface toolkit",26+ long_description=readme,27+ packages=["click"],28+ include_package_data=True,29+ python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*",30 classifiers=[43- 'Development Status :: 5 - Production/Stable',44- 'Intended Audience :: Developers',45- 'License :: OSI Approved :: BSD License',46- 'Operating System :: OS Independent',47- 'Programming Language :: Python',48- 'Programming Language :: Python :: 2',49- 'Programming Language :: Python :: 2.7',50- 'Programming Language :: Python :: 3',51- 'Programming Language :: Python :: 3.4',52- 'Programming Language :: Python :: 3.5',53- 'Programming Language :: Python :: 3.6',54- 'Programming Language :: Python :: 3.7',31+ "Development Status :: 5 - Production/Stable",32+ "Intended Audience :: Developers",33+ "License :: OSI Approved :: BSD License",34+ "Operating System :: OS Independent",35+ "Programming Language :: Python",36+ "Programming Language :: Python :: 2",37+ "Programming Language :: Python :: 2.7",38+ "Programming Language :: Python :: 3",39+ "Programming Language :: Python :: 3.4",40+ "Programming Language :: Python :: 3.5",41+ "Programming Language :: Python :: 3.6",42+ "Programming Language :: Python :: 3.7",43 ],56- python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*",44 )modified:tox.ini+8 added-4 removed
1 [tox]2-envlist = py{36,35,34,27,py}2+envlist =3+ py{37,36,35,34,27,py3,py}4+ docs-html5+ coverage-report6+skip_missing_interpreters = true7 8 [testenv]9 passenv = LANG10 deps =11 pytest12 coverage13 colorama10-commands = coverage run -p -m pytest {posargs:tests}14+commands = coverage run -p -m pytest {posargs}15 16 [testenv:docs-html]13-deps = sphinx17+deps = -r docs/requirements.txt18 commands = sphinx-build -W -b html -d {envtmpdir}/doctrees docs {envtmpdir}/html19 20 [testenv:docs-linkcheck]17-deps = sphinx21+deps = -r docs/requirements.txt22 commands = sphinx-build -W -b linkcheck -d {envtmpdir}/doctrees docs {envtmpdir}/linkcheck23 24 [testenv:coverage-report]25 deps = coverage14 unmodified lines