1.1 KiB
1.1 KiB
PR View Timestamp Normalization
Summary
gitlink-cli pr +view now normalizes pull request lifecycle timestamps so merged and closed pull requests expose stable top-level time fields in JSON output.
Command
| Command | Purpose |
|---|---|
gitlink-cli pr +view |
Return PR detail and normalize created_at, merged_at, closed_at, and closed_on when GitLink provides them directly or journals can infer them. |
Behavior
- Promote
created_atandmerged_atfrom nested response objects to the top-level payload. - Backfill
closed_atandclosed_onfor merged pull requests when GitLink omits an explicit close timestamp. - Read issue journals only when a merged or closed pull request is still missing lifecycle timestamps.
- Recognize merge and close journal operations after stripping HTML tags and whitespace.
- Support both
pull_request_statusandpull_request_stausstatus shapes returned by GitLink APIs.
Tests
go test ./shortcuts/pr/...go build ./...go test ./...go run . pr +view --owner Gitlink --repo gitlink-cli -i 15 --format json