(enabledGroups: Set<string>)
| 68 | const kiloclawDevVarsPath = path.join(repoRoot, 'services/kiloclaw/.dev.vars'); |
| 69 | const alwaysOnGroupIds = new Set(getAlwaysOnGroupIds()); |
| 70 | const groupsById = new Map(getGroups().map(g => [g.id, g])); |
| 71 | const sleep = (ms: number) => new Promise<void>(resolve => setTimeout(resolve, ms)); |
| 72 | |
| 73 | function buildSidebarItems(enabledGroups: Set<string>): SidebarItem[] { |
| 74 | const items: SidebarItem[] = []; |
| 75 | for (const group of getGroups()) { |
| 76 | if (group.sectionBreakBefore) { |
| 77 | items.push({ kind: 'spacer' }); |
| 78 | } |
| 79 | items.push({ kind: 'group', groupId: group.id }); |
| 80 | if (enabledGroups.has(group.id)) { |
| 81 | for (const name of getGroupServiceNames(group.id)) { |
| 82 | items.push({ kind: 'service', name, groupId: group.id }); |
| 83 | } |
| 84 | } |
| 85 | } |
| 86 | return items; |
| 87 | } |
no test coverage detected