@brimveyn/aimux-config 0.6.6 → 0.6.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/index.ts +3 -0
- package/src/resolver.ts +1 -0
- package/src/types.ts +38 -1
package/package.json
CHANGED
package/src/index.ts
CHANGED
package/src/resolver.ts
CHANGED
|
@@ -48,6 +48,7 @@ export function resolveConfig(userConfig: AimuxUserConfig): ResolvedConfig {
|
|
|
48
48
|
snippetTriggerChar: resolveSnippetTriggerChar(userConfig.snippetTriggerChar),
|
|
49
49
|
statusBar: userConfig.statusBar ?? {},
|
|
50
50
|
theme: resolveTheme(userConfig.theme),
|
|
51
|
+
worktreeTemplates: userConfig.worktreeTemplates ?? [],
|
|
51
52
|
}
|
|
52
53
|
}
|
|
53
54
|
|
package/src/types.ts
CHANGED
|
@@ -124,6 +124,13 @@ export interface WorkspaceSnapshotV1 {
|
|
|
124
124
|
layoutTree?: LayoutNode
|
|
125
125
|
layoutTrees?: Record<string, LayoutNode>
|
|
126
126
|
tabGroupMap?: Record<string, string>
|
|
127
|
+
/**
|
|
128
|
+
* Last viewed tab per worktree, keyed by worktree id. Optional and additive
|
|
129
|
+
* (no version bump): older builds ignore it, newer builds tolerate its
|
|
130
|
+
* absence. Written now so the data accrues, but restoring it at startup is
|
|
131
|
+
* gated off until a future change flips RESTORE_LAST_ACTIVE_TAB_BY_WORKTREE.
|
|
132
|
+
*/
|
|
133
|
+
lastActiveTabByWorktree?: Record<string, string>
|
|
127
134
|
}
|
|
128
135
|
|
|
129
136
|
export type WorktreeSource = 'primary' | 'aimux-temp' | 'external'
|
|
@@ -294,7 +301,7 @@ export interface ModalNewTab extends ModalBase {
|
|
|
294
301
|
branchName: string
|
|
295
302
|
createWorktree: boolean
|
|
296
303
|
selectedAssistantId: AssistantId | null
|
|
297
|
-
step: 'assistant' | 'worktree' | 'worktree-create'
|
|
304
|
+
step: 'assistant' | 'worktree' | 'worktree-create' | 'template'
|
|
298
305
|
targetWorktreeIndex: number
|
|
299
306
|
worktreeDeleteConfirmId: string | null
|
|
300
307
|
worktreeDeleteMessage: string | null
|
|
@@ -446,7 +453,9 @@ export interface AppState {
|
|
|
446
453
|
autoCommit: AutoCommitState
|
|
447
454
|
multiRepo: MultiRepoState
|
|
448
455
|
worktreeDivergence: Record<string, BranchDivergence>
|
|
456
|
+
lastActiveTabByWorktree: Record<string, string>
|
|
449
457
|
pendingChords: string[] | null
|
|
458
|
+
worktreeTemplates: WorktreeTemplate[]
|
|
450
459
|
}
|
|
451
460
|
|
|
452
461
|
// ─── AppAction union ──────────────────────────────────────────────────────────
|
|
@@ -460,6 +469,8 @@ export type ModalAction =
|
|
|
460
469
|
message: string | null
|
|
461
470
|
}
|
|
462
471
|
| { type: 'enter-new-tab-worktree-create' }
|
|
472
|
+
| { type: 'enter-new-tab-template-pick' }
|
|
473
|
+
| { type: 'enter-new-tab-template-shortcut' }
|
|
463
474
|
| { type: 'select-new-tab-assistant'; assistantId?: AssistantId }
|
|
464
475
|
| { type: 'toggle-new-tab-worktree'; assistantId?: AssistantId }
|
|
465
476
|
| { type: 'open-help-modal'; scope?: ModeId }
|
|
@@ -590,6 +601,26 @@ export interface BranchDivergence {
|
|
|
590
601
|
behind: number
|
|
591
602
|
}
|
|
592
603
|
|
|
604
|
+
export interface WorktreeTemplatePane {
|
|
605
|
+
id: string
|
|
606
|
+
assistant: string
|
|
607
|
+
splitFrom?: string
|
|
608
|
+
direction?: SplitDirection
|
|
609
|
+
ratio?: number
|
|
610
|
+
send?: string
|
|
611
|
+
}
|
|
612
|
+
|
|
613
|
+
export interface WorktreeTemplateTab {
|
|
614
|
+
panes: WorktreeTemplatePane[]
|
|
615
|
+
}
|
|
616
|
+
|
|
617
|
+
export interface WorktreeTemplate {
|
|
618
|
+
id: string
|
|
619
|
+
name: string
|
|
620
|
+
description?: string
|
|
621
|
+
tabs: WorktreeTemplateTab[]
|
|
622
|
+
}
|
|
623
|
+
|
|
593
624
|
export type GitPanelAction =
|
|
594
625
|
| { type: 'git-refresh-success'; payload: GitRefreshPayload }
|
|
595
626
|
| { type: 'git-refresh-error'; kind: GitPanelError }
|
|
@@ -1038,6 +1069,11 @@ export interface AimuxUserConfig {
|
|
|
1038
1069
|
statusBar?: StatusBarConfig
|
|
1039
1070
|
externalEditor?: ExternalEditorConfig
|
|
1040
1071
|
integrations?: AimuxIntegrationsConfig
|
|
1072
|
+
/**
|
|
1073
|
+
* Worktree templates: layouts (multi-pane + initial commands) applied at
|
|
1074
|
+
* worktree creation. Selected from a picker in the new-tab modal.
|
|
1075
|
+
*/
|
|
1076
|
+
worktreeTemplates?: WorktreeTemplate[]
|
|
1041
1077
|
}
|
|
1042
1078
|
|
|
1043
1079
|
// ─── Resolved config (internal) ───────────────────────────────────────────────
|
|
@@ -1114,4 +1150,5 @@ export interface ResolvedConfig {
|
|
|
1114
1150
|
integrations: {
|
|
1115
1151
|
claudeHooks: boolean
|
|
1116
1152
|
}
|
|
1153
|
+
worktreeTemplates: WorktreeTemplate[]
|
|
1117
1154
|
}
|