feat(settings): choose how new worktrees initialize submodules (#12955)
Co-authored-by: Claude Fable 5 <[email protected]>
This commit is contained in:
1 parent
742173a132
commit
0141bc2bf5
18 files changed
+331
-55
No files matched your search
@@ -2543,11 +2543,20 @@ export const make = Effect.gen(function* () {
|
||||
});
|
||||
}
|
||||
|
||||
const worktree = yield* gitCore.createWorktree({
|
||||
cwd: input.cwd,
|
||||
refName: localPullRequestBranch,
|
||||
path: null,
|
||||
});
|
||||
const worktree = yield* gitCore.createWorktree(
|
||||
{
|
||||
cwd: input.cwd,
|
||||
refName: localPullRequestBranch,
|
||||
path: null,
|
||||
},
|
||||
{
|
||||
// Best effort: a settings read failure falls back to the checkout's t3.json.
|
||||
submodules: yield* projectSettingsFor(input).pipe(
|
||||
Effect.map((settings) => settings.worktreeSubmodules),
|
||||
Effect.orElseSucceed(() => null),
|
||||
),
|
||||
},
|
||||
);
|
||||
yield* ensureExistingWorktreeUpstream(worktree.worktree.path);
|
||||
yield* maybeRunSetupScript(worktree.worktree.path);
|
||||
|
||||
|
||||
Reference in new issue
Block a user