Files
skills/tracker/README.md
T

31 lines
1.3 KiB
Markdown

# Tracker automation
`tracker` is the provider-neutral execution seam for issue-tracker skills. It emits one JSON envelope on stdout and delegates authentication and repository work to `gh`, `glab`, or `tea`.
## Use
```sh
python -m tracker --provider gitea issue get 16
TRACKER_PROVIDER=github tracker issue list --state open --label ready-for-agent
tracker pr get 42 --diff
```
Provider precedence is `--provider`, `TRACKER_PROVIDER`, then the `origin` Git remote. Explicit resource commands (`issue` and `pr`) avoid shared-number ambiguity. Use `resolve-reference` only when intentional resolution of a bare number is required.
Stable failures are returned as:
```json
{"ok":false,"provider":"gitea","operation":"issue.get","error":{"code":"auth_required","message":"...","retryable":false,"provider":"gitea","operation":"issue.get","details":{}}}
```
The Python API is the same seam as the CLI:
```python
from tracker import Tracker
tracker = Tracker(provider="gitea")
result = tracker.add_label("issue", 16, "needs-review")
```
Inject `RecordingRunner` or another object with `run(argv, **kwargs)` for deterministic contract tests. Provider-specific capability gaps are explicit in `error.code` or `details`; credentials are never accepted or stored by this package.