-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathsetup.py
More file actions
30 lines (23 loc) · 952 Bytes
/
Copy pathsetup.py
File metadata and controls
30 lines (23 loc) · 952 Bytes
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
from pathlib import Path
from setuptools import setup
ROOT = Path(__file__).parent
ASSET_ROOTS = ["skills", ".codebuddy", ".codex", ".cursor", ".claude"]
def data_files():
result = [("share/devflow", ["THIRD_PARTY_NOTICES.md"])]
for root_name in ASSET_ROOTS:
source_root = ROOT / root_name
grouped = {}
for path in source_root.rglob("*"):
relative = path.relative_to(source_root)
if (
not path.is_file()
or "tests" in relative.parts
or "__pycache__" in relative.parts
or path.suffix == ".pyc"
):
continue
target = Path("share/devflow") / path.parent.relative_to(ROOT)
grouped.setdefault(str(target), []).append(str(path.relative_to(ROOT)))
result.extend((target, paths) for target, paths in sorted(grouped.items()))
return result
setup(data_files=data_files())