Skip to content

Commit

Permalink
Merge pull request #64 from hugovk/setup-py-to-cfg
Browse files Browse the repository at this point in the history
Setup: Use declarative metadata
  • Loading branch information
hugovk authored Oct 2, 2021
2 parents e867dc5 + b718d08 commit 87d6eb2
Show file tree
Hide file tree
Showing 3 changed files with 58 additions and 48 deletions.
6 changes: 6 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,12 @@ repos:
- id: requirements-txt-fixer
- id: trailing-whitespace

- repo: https://github.com/asottile/setup-cfg-fmt
rev: v1.17.0
hooks:
- id: setup-cfg-fmt
args: ["--max-py-version=3.10"]

- repo: https://github.com/tox-dev/tox-ini-fmt
rev: 0.5.1
hooks:
Expand Down
52 changes: 52 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -1,3 +1,55 @@
[metadata]
name = em_keyboard
description = The CLI Emoji Keyboard
long_description = file: README.md
long_description_content_type = text/markdown
url = https://github.com/hugovk/em-keyboard
author = Kenneth Reitz
author_email = [email protected]
maintainer = Hugo van Kemenade
license = ISC
license_file = LICENSE
classifiers =
Development Status :: 5 - Production/Stable
Intended Audience :: Developers
License :: OSI Approved :: ISC License (ISCL)
Natural Language :: English
Programming Language :: Python
Programming Language :: Python :: 3
Programming Language :: Python :: 3 :: Only
Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
Programming Language :: Python :: 3.9
Programming Language :: Python :: 3.10
Programming Language :: Python :: Implementation :: CPython
keywords =
CLI
emoji
keyboard
search
project_urls =
Source=https://github.com/hugovk/em-keyboard

[options]
install_requires =
pyperclip;platform_system == 'Darwin'
pyperclip;platform_system == 'Windows'
python_requires = >=3.6
include_package_data = True
setup_requires =
setuptools_scm
zip_safe = False

[options.entry_points]
console_scripts =
em=em:cli

[options.extras_require]
tests =
pytest
pytest-cov

[flake8]
max_line_length = 88

Expand Down
48 changes: 0 additions & 48 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
from setuptools import setup

with open("README.md", encoding="utf-8") as f:
long_description = f.read()


def local_scheme(version):
"""Skip the local version (eg. +xyz of 0.6.1.dev4+gdf99fe2)
Expand All @@ -11,50 +8,5 @@ def local_scheme(version):


setup(
name="em-keyboard",
description="The CLI Emoji Keyboard",
long_description=long_description,
long_description_content_type="text/markdown",
author="Kenneth Reitz",
author_email="[email protected]",
maintainer="Hugo van Kemenade",
url="https://github.com/hugovk/em-keyboard",
license="ISC",
keywords=[
"CLI",
"emoji",
"keyboard",
"search",
],
packages=["em"],
package_data={"": ["LICENSE", "NOTICE"], "em": ["emojis.json"]},
include_package_data=True,
entry_points={"console_scripts": ["em=em:cli"]},
zip_safe=False,
use_scm_version={"local_scheme": local_scheme},
setup_requires=["setuptools_scm"],
install_requires=[
"pyperclip; platform_system == 'Darwin'",
"pyperclip; platform_system == 'Windows'",
],
extras_require={"tests": ["pytest", "pytest-cov"]},
python_requires=">=3.6",
project_urls={
"Source": "https://github.com/hugovk/em-keyboard",
},
classifiers=[
# 'Development Status :: 5 - Production/Stable',
"Intended Audience :: Developers",
"License :: OSI Approved :: ISC License (ISCL)",
"Natural Language :: English",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: Implementation :: CPython",
],
)

0 comments on commit 87d6eb2

Please sign in to comment.