forgejo/routers
Gergely Nagy f7535a1cef
[GITEA] allow viewing the latest Action Run on the web
Similar to how some other parts of the web UI support a `/latest` path
to directly go to the latest of a certain thing, let the Actions web UI
do the same: `/{owner}/{repo}/actions/runs/latest` will redirect to the
latest run, if there's one available.

Fixes gitea#27991.

Signed-off-by: Gergely Nagy <forgejo@gergo.csillger.hu>
(cherry picked from commit f67ccef1dd)

Code cleanup in the actions.ViewLatest route handler

Based on feedback received after the feature was merged, use
`ctx.NotFound` and `ctx.ServerError`, and drop the use of the
unnecessary `ctx.Written()`.

Signed-off-by: Gergely Nagy <forgejo@gergo.csillger.hu>
(cherry picked from commit 74e42da563)
2023-12-11 16:08:43 +01:00
..
api [GITEA] Make HTTPS schema default for Swagger 2023-12-11 16:08:43 +01:00
common Clean up template locale usage (#27856) 2023-10-31 22:11:48 +08:00
install [GITEA] Add password length check on install page 2023-12-11 15:46:54 +01:00
private [CLI] implement forgejo-cli 2023-12-11 13:55:27 +01:00
utils Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
web [GITEA] allow viewing the latest Action Run on the web 2023-12-11 16:08:43 +01:00
init.go [API] Forgejo API /api/forgejo/v1 2023-12-11 14:48:35 +01:00