fix(tmux): conditionally mark server running and add interactive bash helper
🤖 Generated with assistance of [OhMyOpenCode](https://github.com/code-yeongyu/oh-my-opencode)
This commit is contained in:
@@ -28,7 +28,9 @@ export function createManagers(args: {
|
||||
}): Managers {
|
||||
const { ctx, pluginConfig, tmuxConfig, modelCacheState, backgroundNotificationHookEnabled } = args
|
||||
|
||||
markServerRunningInProcess()
|
||||
if (tmuxConfig.enabled) {
|
||||
markServerRunningInProcess()
|
||||
}
|
||||
const tmuxSessionManager = new TmuxSessionManager(ctx, tmuxConfig)
|
||||
|
||||
registerManagerForCleanup({
|
||||
|
||||
@@ -7,6 +7,12 @@ export function isTmuxIntegrationEnabled(
|
||||
return pluginConfig.tmux?.enabled ?? false
|
||||
}
|
||||
|
||||
export function isInteractiveBashEnabled(
|
||||
which: (binary: string) => string | null = Bun.which,
|
||||
): boolean {
|
||||
return which("tmux") !== null
|
||||
}
|
||||
|
||||
export function createRuntimeTmuxConfig(pluginConfig: { tmux?: OhMyOpenCodeConfig["tmux"] }): TmuxConfig {
|
||||
return TmuxConfigSchema.parse(pluginConfig.tmux ?? {})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user