CanClean returns true if the selected entry is a non-running PRD with a worktree.
()
| 341 | |
| 342 | // CanClean returns true if the selected entry is a non-running PRD with a worktree. |
| 343 | func (p *PRDPicker) CanClean() bool { |
| 344 | entry := p.GetSelectedEntry() |
| 345 | if entry == nil || entry.WorktreeDir == "" { |
| 346 | return false |
| 347 | } |
| 348 | // Disabled for running PRDs - user must stop first |
| 349 | return entry.LoopState != loop.LoopStateRunning |
| 350 | } |
| 351 | |
| 352 | // StartCleanConfirmation opens the clean confirmation dialog for the selected entry. |
| 353 | func (p *PRDPicker) StartCleanConfirmation() { |