@@ -32,6 +32,7 @@ import { Popover, PopoverPopup, PopoverTrigger } from "~/components/ui/popover";
3232import { ScrollArea } from "~/components/ui/scroll-area" ;
3333import { Textarea } from "~/components/ui/textarea" ;
3434import { toastManager } from "~/components/ui/toast" ;
35+ import { useAppSettings } from "~/appSettings" ;
3536import { openInPreferredEditor } from "~/editorPreferences" ;
3637import {
3738 gitBranchesQueryOptions ,
@@ -158,6 +159,7 @@ export default function GitActionsControl({ gitCwd, activeThreadId }: GitActions
158159 ( ) => ( activeThreadId ? { threadId : activeThreadId } : undefined ) ,
159160 [ activeThreadId ] ,
160161 ) ;
162+ const { settings } = useAppSettings ( ) ;
161163 const queryClient = useQueryClient ( ) ;
162164 const [ isCommitDialogOpen , setIsCommitDialogOpen ] = useState ( false ) ;
163165 const [ dialogCommitMessage , setDialogCommitMessage ] = useState ( "" ) ;
@@ -199,6 +201,7 @@ export default function GitActionsControl({ gitCwd, activeThreadId }: GitActions
199201 useIsMutating ( { mutationKey : gitMutationKeys . runStackedAction ( gitCwd ) } ) > 0 ;
200202 const isPullRunning = useIsMutating ( { mutationKey : gitMutationKeys . pull ( gitCwd ) } ) > 0 ;
201203 const isGitActionRunning = isRunStackedActionRunning || isPullRunning ;
204+ const configuredCommitFlags = settings . gitCommitFlags . trim ( ) ;
202205 const isDefaultBranch = useMemo ( ( ) => {
203206 const branchName = gitStatusForActions ?. branch ;
204207 if ( ! branchName ) return false ;
@@ -349,6 +352,7 @@ export default function GitActionsControl({ gitCwd, activeThreadId }: GitActions
349352 const promise = runImmediateGitActionMutation . mutateAsync ( {
350353 action,
351354 ...( commitMessage ? { commitMessage } : { } ) ,
355+ ...( configuredCommitFlags ? { commitFlags : configuredCommitFlags } : { } ) ,
352356 ...( featureBranch ? { featureBranch } : { } ) ,
353357 ...( filePaths ? { filePaths } : { } ) ,
354358 } ) ;
@@ -442,6 +446,7 @@ export default function GitActionsControl({ gitCwd, activeThreadId }: GitActions
442446 } ,
443447
444448 [
449+ configuredCommitFlags ,
445450 isDefaultBranch ,
446451 runImmediateGitActionMutation ,
447452 setPendingDefaultBranchAction ,
0 commit comments