Repository navigation
Expand file tree
/
Copy pathpyproject.toml
More file actions
81 lines (69 loc) · 2.04 KB
/
Copy pathpyproject.toml
File metadata and controls
81 lines (69 loc) · 2.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
[project]
name = "codemaru"
# Single source of truth: codemaru/__init__.py:__version__ (read by hatchling).
dynamic = ["version"]
description = "Render developer programming activity as an embeddable SVG card for GitHub profile READMEs"
readme = "README.md"
requires-python = ">=3.12"
dependencies = [
"fastapi>=0.138.1",
"pydantic>=2.9.0",
"pydantic-settings>=2.5.0",
"jinja2>=3.1.4",
"httpx>=0.27.0",
# solved.ac sits behind Cloudflare and rejects plain-Python TLS fingerprints;
# curl_cffi impersonates a real browser's TLS so the public API responds.
"curl_cffi>=0.7.0",
# Outlines card text to vector paths so the designed fonts render identically
# everywhere (GitHub README SVGs ignore @font-face / web fonts).
"fonttools>=4.50.0",
]
[dependency-groups]
dev = [
"pytest>=8.3.0",
"pytest-asyncio>=0.24.0",
"pytest-cov>=5.0.0",
"httpx>=0.27.0",
"uvicorn[standard]>=0.49.0",
"ruff>=0.15.20",
"mypy>=1.13.0",
]
[project.scripts]
# Static card generation, used by the GitHub Action (action.yml).
codemaru = "codemaru.cli:main"
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.hatch.version]
path = "codemaru/__init__.py"
[tool.hatch.build.targets.wheel]
packages = ["codemaru"]
[tool.ruff]
line-length = 100
target-version = "py312"
[tool.ruff.lint]
select = ["E", "F", "I", "UP", "B", "SIM", "C4"]
[tool.ruff.lint.per-file-ignores]
"tests/*" = ["B"]
# SVG-builder modules are dense f-string markup where hard-wrapping at 100 cols
# hurts readability more than it helps.
"codemaru/render/icons.py" = ["E501"]
"codemaru/render/card.py" = ["E501"]
[tool.pytest.ini_options]
testpaths = ["tests"]
asyncio_mode = "auto"
addopts = "-q"
markers = [
"integration: live external API tests, excluded from default CI runs",
]
[tool.mypy]
python_version = "3.12"
packages = ["codemaru"]
strict = true
plugins = ["pydantic.mypy"]
[[tool.mypy.overrides]]
module = "curl_cffi.*"
ignore_missing_imports = true
[[tool.mypy.overrides]]
module = "fontTools.*"
ignore_missing_imports = true