9a5750ddca
Expose the same 66 Gitea tools two ways from server/gitea_mcp.py:
- MCP server (no subcommand -> mcp.run()), as before
- CLI: `<tool> --flags` prints one JSON object {success, data/error}
A new @tool decorator registers each function in both FastMCP and a TOOLS
registry; a CLI dispatcher builds argparse from each function's signature and
wraps results in the repo's JSON+success contract. Adds `list-tools` for
discovery. No tool logic duplicated.
- Rewrite skills/gitea/SKILL.md for CLI-first usage (MCP kept as an option)
- Sync version to 0.3.0 across plugin.json, pyproject.toml, SKILL.md
- Add tests/unit/test_cli.py (dispatch routing, flag typing, errors, main)
- Document dual-mode in README.md and CLAUDE.md
- Ignore coverage artifacts
Tests: 119 passed, 93% coverage.
28 lines
387 B
Plaintext
28 lines
387 B
Plaintext
# Credentials — never commit real tokens
|
|
config.json
|
|
|
|
# Python
|
|
.venv/
|
|
__pycache__/
|
|
*.pyc
|
|
*.pyo
|
|
*.egg-info/
|
|
dist/
|
|
.env
|
|
|
|
# Test / coverage artifacts
|
|
.coverage
|
|
.coverage.*
|
|
.pytest_cache/
|
|
htmlcov/
|
|
|
|
# Gitea API spec — large auto-generated file, download from your Gitea instance
|
|
gitea-api.yaml
|
|
|
|
# Claude Code local settings
|
|
.claude/settings.local.json
|
|
|
|
# IDE
|
|
.idea/
|
|
.vscode/settings.json
|