GeezerVison is showing github.com — Add default new-thread worktree mode with draft defaults by notkainoa · Pull Request #1007 · pingdotgg/t3code
Conversation
notkainoa
commented
Mar 13, 2026
•
edited by macroscopeapp
Bot
Loading
Uh oh!
There was an error while loading. Please reload this page.
Add a setting to choose the default mode for new threads: Local or New worktree.
What changed
-
Added a default new-thread setting: Local or New worktree.
-
Unified the sidebar button and chat.new to use the same draft setup logic.
-
New worktree now opens as a pending draft and creates the worktree on first send.
-
chat.newLocal still always opens a local draft.
-
Reopening an unsent draft now preserves its branch and mode.
Local.vs.Worktree.for.new.thread.mp4
Note
Add default new-thread worktree mode with settings toggle and draft defaults
- Introduces
buildNewThreadDraftDefaults in threadDraftDefaults.ts to compute envMode and initial branch for new draft threads based on user preference and current git status.
- Adds
newThreadUsesNewWorktree (default false) to AppSettingsSchema in appSettings.ts, with a settings UI toggle in _chat.settings.tsx to switch between local and new-worktree modes.
- Refactors
handleNewThread in Sidebar.tsx to use computed defaults instead of manual branching/worktree overrides; the chat.newLocal shortcut forces local mode.
- Fixes older persisted settings missing new fields by shallow-merging them with schema defaults on read.
- Behavioral Change: new draft threads now default to local mode unless the user enables the new-worktree setting; the
chat.new shortcut no longer accepts explicit branch/worktree overrides.
Macroscope summarized c55c17b. (Automatic summaries will resume when PR exits draft mode or review begins).
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
- add `newThreadUsesNewWorktree` app setting and Threads mode selector in Settings
- centralize new-thread draft initialization in `buildNewThreadDraftDefaults`
- make Sidebar new-thread flow use resolved defaults (with force-local shortcut support)
- backfill settings parsing for older persisted payloads and add coverage for worktree-first send flow
coderabbitai
Bot
commented
Mar 13, 2026
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
Important
Review skipped
Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: af0c2422-5226-4a12-b3e7-4d37d7c8a840
You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.
Use the checkbox below for a quick retry:
✨ Finishing Touches
🧪 Generate unit tests (beta)
- Create PR with unit tests
- Post copyable unit tests in a comment
📝 Coding Plan
- Generate coding plan for human review comments
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
❤️ Share
Comment @coderabbitai help to get the list of available commands and usage tips.
Tip
CodeRabbit can use Trivy to scan for security misconfigurations and secrets in Infrastructure as Code files.
Add a .trivyignore file to your project to customize which findings Trivy reports.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
- Stop recomputing defaults when reselecting an existing project draft thread
- Keep existing draft branch/mode context instead of resetting it in Sidebar flow
- Fallback to worktree mode with null branch when `git.status` fails
- Add tests for reopening existing drafts and git status failure handling
|
just merged a different PR doing this (#892) although i do think your settings UI fits more so happy to get that int
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Labels
size:XL
500-999 changed lines (additions + deletions).
vouch:trusted
Author is trusted by repo permissions or the VOUCHED list.
Milestone
No milestone
Development
Successfully merging this pull request may close these issues.
Uh oh!
There was an error while loading. Please reload this page.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.