From 53ea1f4837ef813255743f82e16f4c1b3ffbee95 Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 20 Sep 2026 15:32:48 +0000 Subject: [PATCH 1/2] fix(fixtures): pin the workspace_flow branch to main MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit fixtures/workspace_flow/bootstrap.sh created its four repositories with a bare `git init`, so the branch was whatever the host git defaulted to. Two tests built on that fixture name `main`, and fail wherever init.defaultBranch is unset and git still defaults to `master`: t9014-workspace-hub-flow.sh 0 of 2 passed t90010-workspace-git-compat.sh 5 of 7 passed t9014 broke in its setup, where `git checkout main` found no such pathspec and `bit hub pr create --base refs/heads/main` then reported "Target branch not found"; t90010 broke on `git push -u origin main`. Set HEAD while it is still unborn rather than passing `git init -b`, which needs git 2.28 — the script is otherwise plain POSIX sh with no version floor. Both tests now pass with init.defaultBranch unset, and the seven other tests on this fixture are unaffected: they never name a branch. Fixes #191 Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01VDVUJHu38YtVAr6sKZtRDB --- fixtures/workspace_flow/bootstrap.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/fixtures/workspace_flow/bootstrap.sh b/fixtures/workspace_flow/bootstrap.sh index 06e1804a..d1b1dadc 100755 --- a/fixtures/workspace_flow/bootstrap.sh +++ b/fixtures/workspace_flow/bootstrap.sh @@ -21,6 +21,11 @@ init_repo() { ( cd "$repo_dir" git init -q + # Pin the branch rather than inheriting the host's default. Tests built + # on this fixture name `main`, and git still defaults to `master` where + # init.defaultBranch is unset. Setting HEAD while it is unborn works on + # every git version, unlike `git init -b`. + git symbolic-ref HEAD refs/heads/main git config user.email "fixture@example.com" git config user.name "Fixture User" printf "%s\n" "$file_content" > "$file_name" From 739245a6c693ec6923f38b932cdd8ec63fa4b6de Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 20 Sep 2026 16:29:21 +0000 Subject: [PATCH 2/2] chore: ignore the t/ trash directories left by failing tests t/test-lib.sh removes TRASH_DIRECTORY only when the whole file passes, so every red run leaves one behind. Six of them accumulated while triaging the t900 failures (#193-#198), and untracked scratch repositories next to the tests are easy to commit by accident. Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01VDVUJHu38YtVAr6sKZtRDB --- .gitignore | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.gitignore b/.gitignore index 9a81b694..4b9b03bd 100644 --- a/.gitignore +++ b/.gitignore @@ -42,6 +42,9 @@ t/shim.log t/t0022-shim-random.sh t/tmptrace/ t/trace +# t/test-lib.sh keeps the trash directory when a test fails, so these linger +# after every red run. +t/trash-directory.* tmp/ goodbye.ts version.ts