diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 0000000..d2870e8 --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,25 @@ +repos: + - repo: https://github.com/psf/black + rev: stable + hooks: + - id: black + language_version: python3.8 + + - repo: https://github.com/pre-commit/mirrors-isort + rev: v4.3.21 + hooks: + - id: isort + additional_dependencies: [toml] + language_version: python3.8 + + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v2.4.0 + hooks: + - id: trailing-whitespace + - id: end-of-file-fixer + - id: debug-statements + + - repo: https://github.com/asottile/setup-cfg-fmt + rev: v1.9.0 + hooks: + - id: setup-cfg-fmt diff --git a/pyproject.toml b/pyproject.toml index 2f21011..d780681 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,3 +1,11 @@ [build-system] requires = ["setuptools>=40.8.0", "wheel"] build-backend = "setuptools.build_meta" + +[tool.isort] +atomic=true +force_grid_wrap=0 +include_trailing_comma=true +multi_line_output=3 +not_skip="__init__.py" +use_parentheses=true diff --git a/setup.cfg b/setup.cfg index ddb6c20..77d03f1 100644 --- a/setup.cfg +++ b/setup.cfg @@ -4,31 +4,30 @@ version = attr:tzdata.__version__ description = Provider of IANA time zone data long_description = file: README.md long_description_content_type = text/markdown +url = https://github.com/python/tzdata +author = Python Software Foundation +author_email = datetime-sig@python.org license = Apache-2.0 +license_file = LICENSE license_files = LICENSE licenses/LICENSE_APACHE -url = https://github.com/python/tzdata -author = Python Software Foundation -author_email = paul@ganssle.io classifiers = - Development Status :: 3 - Alpha + Development Status :: 4 - Beta Intended Audience :: Developers License :: OSI Approved :: Apache Software License Programming Language :: Python :: 2 Programming Language :: Python :: 3 - -python_requires = *.* # This is a data-only package - project_urls = Bug Reports = https://github.com/python/tzdata/issues Source = https://github.com/python/tzdata [options] packages = tzdata -include_package_data=True -package_dir= +python_requires = >=2 +include_package_data = True +package_dir = =src [bdist_wheel] -universal=1 +universal = 1 diff --git a/src/tzdata/__init__.py b/src/tzdata/__init__.py index 2e6c9af..bcf2eff 100644 --- a/src/tzdata/__init__.py +++ b/src/tzdata/__init__.py @@ -4,4 +4,3 @@ # This exposes the original IANA version number. IANA_VERSION = "2020a" - diff --git a/templates/__init__.py.in b/templates/__init__.py.in index b6cf3c7..32b11f7 100644 --- a/templates/__init__.py.in +++ b/templates/__init__.py.in @@ -4,4 +4,3 @@ __version__ = %%PACKAGE_VERSION%% # This exposes the original IANA version number. IANA_VERSION = %%IANA_VERSION%% -