(loop)
| 46 | } |
| 47 | |
| 48 | function formatLoop(loop) { |
| 49 | const status = loop.status || 'planned'; |
| 50 | const terminal = isTerminalStatus(status) ? 'stopped' : 'active'; |
| 51 | const cadence = loop.trigger?.cadence ? ` | ${loop.trigger.cadence}` : ''; |
| 52 | const verifier = loop.verifier?.command || loop.verifier?.profile || 'none'; |
| 53 | return [ |
| 54 | `- ${loop.id} [${status}/${terminal}]`, |
| 55 | ` Type: ${loop.type || 'loop'}${cadence}`, |
| 56 | ` Title: ${loop.title || loop.id}`, |
| 57 | ` Verifier: ${verifier}`, |
| 58 | ` State: ${loop.statePath || '(unknown)'}`, |
| 59 | ` Source: ${loop.source || 'loop-registry'}`, |
| 60 | ].join('\n'); |
| 61 | } |
| 62 | |
| 63 | function renderList(loops) { |
| 64 | if (!loops.length) return 'No Citadel loops found.\n'; |
no test coverage detected