From 6ef8c052f4b66b670b54c2c71ef9c6171cba0183 Mon Sep 17 00:00:00 2001 From: Alexander Ivanov Date: Wed, 14 Oct 2026 07:34:01 +0300 Subject: [PATCH] Archive a-detached-directory-is-offered-for-removal - a-detached-directory-is-offered-for-removal Opened by the workspace sweep: each landed with nothing open (ADR 0035). --- .../design.md | 0 .../proposal.md | 0 .../specs/openspec-workbench/spec.md | 0 .../tasks.md | 0 openspec/specs/openspec-workbench/spec.md | 36 +++++++++++++++++++ 5 files changed, 36 insertions(+) rename openspec/changes/{a-detached-directory-is-offered-for-removal => archive/2026-10-14-a-detached-directory-is-offered-for-removal}/design.md (100%) rename openspec/changes/{a-detached-directory-is-offered-for-removal => archive/2026-10-14-a-detached-directory-is-offered-for-removal}/proposal.md (100%) rename openspec/changes/{a-detached-directory-is-offered-for-removal => archive/2026-10-14-a-detached-directory-is-offered-for-removal}/specs/openspec-workbench/spec.md (100%) rename openspec/changes/{a-detached-directory-is-offered-for-removal => archive/2026-10-14-a-detached-directory-is-offered-for-removal}/tasks.md (100%) diff --git a/openspec/changes/a-detached-directory-is-offered-for-removal/design.md b/openspec/changes/archive/2026-10-14-a-detached-directory-is-offered-for-removal/design.md similarity index 100% rename from openspec/changes/a-detached-directory-is-offered-for-removal/design.md rename to openspec/changes/archive/2026-10-14-a-detached-directory-is-offered-for-removal/design.md diff --git a/openspec/changes/a-detached-directory-is-offered-for-removal/proposal.md b/openspec/changes/archive/2026-10-14-a-detached-directory-is-offered-for-removal/proposal.md similarity index 100% rename from openspec/changes/a-detached-directory-is-offered-for-removal/proposal.md rename to openspec/changes/archive/2026-10-14-a-detached-directory-is-offered-for-removal/proposal.md diff --git a/openspec/changes/a-detached-directory-is-offered-for-removal/specs/openspec-workbench/spec.md b/openspec/changes/archive/2026-10-14-a-detached-directory-is-offered-for-removal/specs/openspec-workbench/spec.md similarity index 100% rename from openspec/changes/a-detached-directory-is-offered-for-removal/specs/openspec-workbench/spec.md rename to openspec/changes/archive/2026-10-14-a-detached-directory-is-offered-for-removal/specs/openspec-workbench/spec.md diff --git a/openspec/changes/a-detached-directory-is-offered-for-removal/tasks.md b/openspec/changes/archive/2026-10-14-a-detached-directory-is-offered-for-removal/tasks.md similarity index 100% rename from openspec/changes/a-detached-directory-is-offered-for-removal/tasks.md rename to openspec/changes/archive/2026-10-14-a-detached-directory-is-offered-for-removal/tasks.md diff --git a/openspec/specs/openspec-workbench/spec.md b/openspec/specs/openspec-workbench/spec.md index b2782976..c1969000 100644 --- a/openspec/specs/openspec-workbench/spec.md +++ b/openspec/specs/openspec-workbench/spec.md @@ -865,3 +865,39 @@ month later the line is all there is of it. is ticked - **THEN** its line names what the sweep did, on what, and when it was seen + +### Requirement: A working directory on no branch is finished with where the default branch contains its commit + +A surveyed working directory on no branch SHALL be reported as finished +with where the default branch already contains the commit it is at, its +tree is clean and no run is recorded against it. It SHALL be reported as +`merged` and SHALL name no branch. + +It SHALL be offered for removal beside a press and SHALL NOT be removed by +a sweep: a directory on no branch cannot be told from one made a moment ago +for work still to come, and removing it unasked can take it from under +somebody. + +#### Scenario: A detached directory at a commit main contains + +- **WHEN** a directory is on no branch, at a commit the default branch + contains, its tree is clean and no run is recorded against it +- **THEN** it is reported as finished with, naming no branch, and is + offered for removal + +#### Scenario: A detached directory ahead of main + +- **WHEN** a directory is on no branch and its commit is not contained in + the default branch +- **THEN** it is not reported as finished with + +#### Scenario: A detached directory that holds work or a run + +- **WHEN** such a directory's tree is not clean, or a run is recorded + against it +- **THEN** it is not reported as finished with + +#### Scenario: The sweep meets a detached directory + +- **WHEN** the workspace sweep reads a directory on no branch +- **THEN** it keeps it, as it did, and removes nothing