type Approval.agent as Ident

This commit is contained in:
damocles 2026-07-22 19:38:23 +02:00 committed by mara
commit 76647415af
10 changed files with 71 additions and 53 deletions

View file

@ -552,7 +552,7 @@ fn history_view(a: Approval) -> ApprovalHistoryView {
let kind = a.kind.as_str();
ApprovalHistoryView {
id: a.id,
agent: a.agent,
agent: a.agent.to_string(),
kind,
sha_short,
status,
@ -567,7 +567,7 @@ fn build_approval_views(approvals: Vec<Approval>) -> Vec<ApprovalView> {
out.push(match a.kind {
hive_sh4re::ApprovalKind::Spawn => ApprovalView {
id: a.id,
agent: a.agent,
agent: a.agent.to_string(),
kind: "spawn",
sha_short: None,
description: a.description,
@ -577,7 +577,7 @@ fn build_approval_views(approvals: Vec<Approval>) -> Vec<ApprovalView> {
},
hive_sh4re::ApprovalKind::InitConfig => ApprovalView {
id: a.id,
agent: a.agent,
agent: a.agent.to_string(),
kind: "init_config",
sha_short: None,
description: a.description,
@ -587,7 +587,7 @@ fn build_approval_views(approvals: Vec<Approval>) -> Vec<ApprovalView> {
},
hive_sh4re::ApprovalKind::UpdateMetaInputs => ApprovalView {
id: a.id,
agent: a.agent,
agent: a.agent.to_string(),
kind: "update_meta_inputs",
sha_short: None,
description: a.description,
@ -597,7 +597,7 @@ fn build_approval_views(approvals: Vec<Approval>) -> Vec<ApprovalView> {
},
hive_sh4re::ApprovalKind::SchedulePrompt => ApprovalView {
id: a.id,
agent: a.agent,
agent: a.agent.to_string(),
kind: "schedule_prompt",
sha_short: None,
description: a.description,
@ -618,7 +618,7 @@ fn build_approval_views(approvals: Vec<Approval>) -> Vec<ApprovalView> {
let pr_number = a.commit_ref.parse::<u64>().ok();
ApprovalView {
id: a.id,
agent: a.agent,
agent: a.agent.to_string(),
kind: "merge_config_pr",
sha_short: sha,
description: a.description,