plugin: honor tmux disablement for interactive tmux features
This commit is contained in:
@@ -1,6 +1,12 @@
|
||||
import type { OhMyOpenCodeConfig, TmuxConfig } from "./config"
|
||||
import { TmuxConfigSchema } from "./config/schema/tmux"
|
||||
|
||||
export function isTmuxIntegrationEnabled(
|
||||
pluginConfig: { tmux?: { enabled?: boolean } | undefined },
|
||||
): boolean {
|
||||
return pluginConfig.tmux?.enabled ?? false
|
||||
}
|
||||
|
||||
export function createRuntimeTmuxConfig(pluginConfig: { tmux?: OhMyOpenCodeConfig["tmux"] }): TmuxConfig {
|
||||
return TmuxConfigSchema.parse(pluginConfig.tmux ?? {})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user