feat(actions): list workflow runs #87

Merged
Claude-Run merged 1 commit from feat/actions-runs-command into main 2026-08-01 04:02:33 +02:00
Member

fj actions could list tasks (one job execution each) but never the workflow-level runs, so a consumer that needs a run's branch, workflow file, or conclusion had to call GET /repos/{owner}/{repo}/actions/runs by hand. fj actions runs now exposes that endpoint, backed by a new fj_core::actions::list_runs wrapper that action_run_logs also uses instead of reaching for api.list_action_runs inline.

Every filter ListActionRunsQuery carries is reachable: --event, --status, --run-number, --head-sha, --ref, and --workflow. --page / --limit ride on the request as the generic paging params the endpoint accepts, since the query struct itself has no paging fields. --event and --status take a single value each because forgejo-api 0.11.0 comma-joins a repeated query value, which Forgejo rejects for status and silently matches nothing for event; a second value is refused with a message naming that cause rather than sent as a query the server misreads.

--json emits the run object flattened in unmodified so no field is lost, plus run_number, head_branch, and conclusion aliases for what Forgejo calls index_in_repo and prettyref and folds into status. The text renderer follows the tasks line shape, and the status glyph both commands draw is now one shared status_symbol helper.

#FJ-66

`fj actions` could list tasks (one job execution each) but never the workflow-level runs, so a consumer that needs a run's branch, workflow file, or conclusion had to call `GET /repos/{owner}/{repo}/actions/runs` by hand. `fj actions runs` now exposes that endpoint, backed by a new `fj_core::actions::list_runs` wrapper that `action_run_logs` also uses instead of reaching for `api.list_action_runs` inline. Every filter `ListActionRunsQuery` carries is reachable: `--event`, `--status`, `--run-number`, `--head-sha`, `--ref`, and `--workflow`. `--page` / `--limit` ride on the request as the generic paging params the endpoint accepts, since the query struct itself has no paging fields. `--event` and `--status` take a single value each because forgejo-api 0.11.0 comma-joins a repeated query value, which Forgejo rejects for `status` and silently matches nothing for `event`; a second value is refused with a message naming that cause rather than sent as a query the server misreads. `--json` emits the run object flattened in unmodified so no field is lost, plus `run_number`, `head_branch`, and `conclusion` aliases for what Forgejo calls `index_in_repo` and `prettyref` and folds into `status`. The text renderer follows the `tasks` line shape, and the status glyph both commands draw is now one shared `status_symbol` helper. #FJ-66
feat(actions): list workflow runs
All checks were successful
Check / fmt + clippy + build + tests (pull_request) Successful in 1m56s
Create release / Create release from merged PR (pull_request) Has been skipped
6311e7ffcd
`fj actions` could list tasks (one job execution each) but never the workflow-level runs, so a consumer that needs a run's branch, workflow file, or conclusion had to call `GET /repos/{owner}/{repo}/actions/runs` by hand. `fj actions runs` now exposes that endpoint, backed by a new `fj_core::actions::list_runs` wrapper that `action_run_logs` also uses instead of reaching for `api.list_action_runs` inline.

Every filter `ListActionRunsQuery` carries is reachable: `--event`, `--status`, `--run-number`, `--head-sha`, `--ref`, and `--workflow`. `--page` / `--limit` ride on the request as the generic paging params the endpoint accepts, since the query struct itself has no paging fields. `--event` and `--status` take a single value each because forgejo-api 0.11.0 comma-joins a repeated query value, which Forgejo rejects for `status` and silently matches nothing for `event`; a second value is refused with a message naming that cause rather than sent as a query the server misreads.

`--json` emits the run object flattened in unmodified so no field is lost, plus `run_number`, `head_branch`, and `conclusion` aliases for what Forgejo calls `index_in_repo` and `prettyref` and folds into `status`. The text renderer follows the `tasks` line shape, and the status glyph both commands draw is now one shared `status_symbol` helper.

#FJ-66
Claude-Run deleted branch feat/actions-runs-command 2026-08-01 04:02:33 +02:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
pandoras-box/forgejo-cli!87
No description provided.