mirror of
https://github.com/HKUDS/CLI-Anything.git
synced 2026-07-07 23:23:40 +08:00
Implements a full CLI harness that converts Draw.io (diagrams.net) into an agent-callable API, following the CLI-Anything 7-phase pipeline pattern. Features: - XML-native manipulation of .drawio files (no GUI required) - 15 shape presets (rectangle, ellipse, diamond, cylinder, cloud, etc.) - 4 edge styles (straight, orthogonal, curved, entity-relation) - Style property system (fill/stroke/font color, opacity, shadow, dashed, etc.) - Multi-page diagram support - Undo/redo with snapshot-based history (50 levels) - Session persistence and auto-save in --project mode - Interactive REPL mode with prompt-toolkit - JSON output mode for AI agent consumption - Export pipeline: XML direct + PNG/SVG/PDF via draw.io desktop CLI - 138 tests passing (116 unit + 22 e2e), 3 skipped (require draw.io desktop) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
54 lines
1.7 KiB
Python
54 lines
1.7 KiB
Python
#!/usr/bin/env python3
|
|
"""
|
|
setup.py for cli-anything-drawio
|
|
|
|
Install with: pip install -e .
|
|
Or publish to PyPI: python -m build && twine upload dist/*
|
|
"""
|
|
|
|
from setuptools import setup, find_namespace_packages
|
|
|
|
with open("cli_anything/drawio/README.md", "r", encoding="utf-8") as fh:
|
|
long_description = fh.read()
|
|
|
|
setup(
|
|
name="cli-anything-drawio",
|
|
version="1.0.0",
|
|
author="cli-anything contributors",
|
|
author_email="",
|
|
description="CLI harness for Draw.io - Diagram creation and export via draw.io CLI. Requires: draw.io desktop app (draw.io --export)",
|
|
long_description=long_description,
|
|
long_description_content_type="text/markdown",
|
|
url="https://github.com/anthropics/cli-anything",
|
|
packages=find_namespace_packages(include=["cli_anything.*"]),
|
|
classifiers=[
|
|
"Development Status :: 4 - Beta",
|
|
"Intended Audience :: Developers",
|
|
"Topic :: Software Development :: Libraries :: Python Modules",
|
|
"Topic :: Office/Business :: Office Suites",
|
|
"License :: OSI Approved :: MIT License",
|
|
"Programming Language :: Python :: 3",
|
|
"Programming Language :: Python :: 3.10",
|
|
"Programming Language :: Python :: 3.11",
|
|
"Programming Language :: Python :: 3.12",
|
|
],
|
|
python_requires=">=3.10",
|
|
install_requires=[
|
|
"click>=8.0.0",
|
|
"prompt-toolkit>=3.0.0",
|
|
],
|
|
extras_require={
|
|
"dev": [
|
|
"pytest>=7.0.0",
|
|
"pytest-cov>=4.0.0",
|
|
],
|
|
},
|
|
entry_points={
|
|
"console_scripts": [
|
|
"cli-anything-drawio=cli_anything.drawio.drawio_cli:cli",
|
|
],
|
|
},
|
|
include_package_data=True,
|
|
zip_safe=False,
|
|
)
|