import os from setuptools import setup, find_packages def parse_requirements(filename): req_path = os.path.join(os.path.dirname(__file__), filename) if not os.path.exists(req_path): return [] with open(req_path, "r", encoding="utf-8") as f: lines = f.read().splitlines() out = [] for line in lines: s = line.strip() if not s or s.startswith("#"): continue # setuptools' extras_require doesn't understand pip's "-r other.txt" # syntax — recurse manually instead. if s.startswith("-r ") or s.startswith("--requirement "): nested = s.split(None, 1)[1].strip() out.extend(parse_requirements(nested)) continue out.append(s) return out here = os.path.abspath(os.path.dirname(__file__)) with open(os.path.join(here, "README.rst"), "r", encoding="utf-8") as f: long_description = f.read() install_requires = parse_requirements("requirements.txt") extras_require = { "dev": parse_requirements("requirements-dev.txt"), "test": parse_requirements("requirements-test.txt"), } setup( name="arborist-viz", version="0.0.1", description=( "Arborist VIZ / Merkle Command Center — a configurable proof-native " "browser dashboard for inspecting arborist's content-addressed state." ), long_description=long_description, long_description_content_type="text/x-rst", author="Russell Ballestrini", author_email="russell@unturf.com", url="https://git.unturf.com/engineering/arborist-viz", keywords="merkle proof audit dashboard pyramid arborist provenance", license="AGPL-3.0-only", include_package_data=True, packages=find_packages(exclude=["tests"]), package_data={ "arborist_viz": [ "templates/*.jinja2", "templates/widgets/*.jinja2", "static/six/*", "static/viz/*", "static/css/*", "scripts/alembic/*.py", "scripts/alembic/*.ini", "scripts/alembic/versions/*.py", ] }, zip_safe=False, install_requires=install_requires, extras_require=extras_require, entry_points={ "paste.app_factory": ["main = arborist_viz:main"], "console_scripts": [ "arborist_viz_init_db = arborist_viz.scripts.init_db:main", "arborist_viz_seed_demo = arborist_viz.scripts.seed_demo:main", ], }, classifiers=[ "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", "Framework :: Pyramid", "License :: OSI Approved :: GNU Affero General Public License v3", "Topic :: Internet :: WWW/HTTP", "Topic :: Internet :: WWW/HTTP :: WSGI :: Application", ], )