pyproject.toml•4.45 kB
[build-system]
requires = ["setuptools>=61.0", "wheel"]
build-backend = "setuptools.build_meta"
[project]
name = "keynote-mcp"
version = "1.0.0"
description = "一个专为大模型设计的 MCP 套件,通过 AppleScript 实现对 Keynote 的全面控制"
readme = "README.md"
license = {text = "MIT"}
authors = [
{name = "Keynote-MCP Team", email = "your-email@example.com"},
]
maintainers = [
{name = "Keynote-MCP Team", email = "your-email@example.com"},
]
keywords = [
"keynote",
"mcp",
"model-context-protocol",
"applescript",
"automation",
"presentation",
"macos",
"ai",
"llm",
]
classifiers = [
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: MacOS",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Multimedia :: Graphics :: Presentation",
"Topic :: Office/Business :: Office Suites",
]
requires-python = ">=3.8"
dependencies = [
"mcp>=1.0.0",
"asyncio-mqtt>=0.16.0",
"pathlib>=1.0.1",
"typing-extensions>=4.0.0",
"aiohttp>=3.8.0",
"aiofiles>=0.8.0",
"Pillow>=9.0.0",
"pytest>=7.0.0",
"python-dotenv>=1.0.0",
]
[project.optional-dependencies]
dev = [
"pytest>=7.0.0",
"pytest-cov>=4.0.0",
"pytest-asyncio>=0.21.0",
"black>=22.0.0",
"isort>=5.0.0",
"flake8>=5.0.0",
"mypy>=1.0.0",
"bandit>=1.7.0",
"safety>=2.0.0",
"pre-commit>=2.20.0",
"coverage>=6.0.0",
]
docs = [
"sphinx>=5.0.0",
"sphinx-rtd-theme>=1.0.0",
"sphinx-autodoc-typehints>=1.19.0",
]
build = [
"build>=0.8.0",
"twine>=4.0.0",
]
[project.urls]
Homepage = "https://github.com/easychen/keynote-mcp"
Repository = "https://github.com/easychen/keynote-mcp"
Documentation = "https://github.com/easychen/keynote-mcp/blob/main/docs/README.md"
"Bug Reports" = "https://github.com/easychen/keynote-mcp/issues"
Changelog = "https://github.com/easychen/keynote-mcp/blob/main/CHANGELOG.md"
[project.scripts]
keynote-mcp = "src.server:main"
[tool.setuptools]
package-dir = {"" = "src"}
[tool.setuptools.packages.find]
where = ["src"]
[tool.setuptools.package-data]
"*" = ["*.scpt", "*.applescript", "*.md", "*.txt"]
# Black 配置
[tool.black]
line-length = 88
target-version = ['py38']
include = '\.pyi?$'
extend-exclude = '''
/(
# directories
\.eggs
| \.git
| \.hg
| \.mypy_cache
| \.tox
| \.venv
| build
| dist
)/
'''
# isort 配置
[tool.isort]
profile = "black"
multi_line_output = 3
line_length = 88
known_first_party = ["src"]
# MyPy 配置
[tool.mypy]
python_version = "3.8"
warn_return_any = true
warn_unused_configs = true
disallow_untyped_defs = true
disallow_incomplete_defs = true
check_untyped_defs = true
disallow_untyped_decorators = true
no_implicit_optional = true
warn_redundant_casts = true
warn_unused_ignores = true
warn_no_return = true
warn_unreachable = true
strict_equality = true
[[tool.mypy.overrides]]
module = [
"mcp.*",
"aiohttp.*",
"aiofiles.*",
"PIL.*",
]
ignore_missing_imports = true
# Pytest 配置
[tool.pytest.ini_options]
testpaths = ["tests"]
python_files = ["test_*.py", "*_test.py"]
python_classes = ["Test*"]
python_functions = ["test_*"]
addopts = [
"--strict-markers",
"--strict-config",
"--verbose",
"--cov=src",
"--cov-report=term-missing",
"--cov-report=html",
"--cov-report=xml",
]
markers = [
"slow: marks tests as slow (deselect with '-m \"not slow\"')",
"integration: marks tests as integration tests",
"unit: marks tests as unit tests",
]
# Coverage 配置
[tool.coverage.run]
source = ["src"]
omit = [
"*/tests/*",
"*/test_*",
"*/__pycache__/*",
"*/venv/*",
"*/env/*",
]
[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"def __repr__",
"if self.debug:",
"if settings.DEBUG",
"raise AssertionError",
"raise NotImplementedError",
"if 0:",
"if __name__ == .__main__.:",
"class .*\\bProtocol\\):",
"@(abc\\.)?abstractmethod",
]
# Bandit 配置
[tool.bandit]
exclude_dirs = ["tests", "venv", "env"]
skips = ["B101", "B601"]