feat(server): run a project action when a worktree thread settles (#16290)
Co-authored-by: spoukyii <[email protected]> Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]>
This commit is contained in:
20 files changed
+409
-56
No files matched your search
@@ -28,6 +28,7 @@ import {
|
||||
buildProjectScript,
|
||||
commandForProjectScript,
|
||||
nextProjectScriptId,
|
||||
releaseClaimedRoles,
|
||||
} from "../../projectScripts";
|
||||
import { useProjects } from "../../state/entities";
|
||||
import { serverEnvironment } from "../../state/server";
|
||||
@@ -194,11 +195,7 @@ export function useProjectScriptSettings(
|
||||
return persist(
|
||||
(current) => {
|
||||
const updated = current.map((script) =>
|
||||
script.id === id
|
||||
? next
|
||||
: input.runOnWorktreeCreate
|
||||
? { ...script, runOnWorktreeCreate: false }
|
||||
: script,
|
||||
script.id === id ? next : releaseClaimedRoles(script, input),
|
||||
);
|
||||
return scriptId === null ? [...updated, next] : updated;
|
||||
},
|
||||
|
||||
Reference in new issue
Block a user