code-squad-cli 1.2.22 → 1.3.0

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.
@@ -0,0 +1,233 @@
1
+ /**
2
+ * tmux 명령어 실행 래퍼
3
+ */
4
+ export declare class TmuxAdapter {
5
+ /**
6
+ * tmux 설치 여부 확인
7
+ */
8
+ isTmuxAvailable(): Promise<boolean>;
9
+ /**
10
+ * 현재 tmux 세션 내부인지 확인
11
+ */
12
+ isInsideTmux(): boolean;
13
+ /**
14
+ * 세션 존재 여부 확인
15
+ */
16
+ hasSession(name: string): Promise<boolean>;
17
+ /**
18
+ * 새 tmux 세션 생성
19
+ */
20
+ createSession(name: string, cwd: string): Promise<void>;
21
+ /**
22
+ * 세션 생성 또는 기존 세션 반환
23
+ * @returns true if new session created, false if existing session
24
+ */
25
+ ensureSession(name: string, cwd: string): Promise<boolean>;
26
+ /**
27
+ * 세션에 attach (spawn 사용)
28
+ */
29
+ attachSession(name: string): Promise<void>;
30
+ /**
31
+ * 현재 pane 분할 (수직/수평)
32
+ * @param direction 'v' = 수직 (좌우), 'h' = 수평 (상하)
33
+ * @param cwd 새 pane의 작업 디렉토리
34
+ * @param percent 새 pane의 크기 비율 (옵션)
35
+ */
36
+ splitWindow(direction: 'v' | 'h', cwd?: string, percent?: number): Promise<string>;
37
+ /**
38
+ * 특정 pane 선택 (포커스)
39
+ */
40
+ selectPane(paneId: string): Promise<void>;
41
+ /**
42
+ * pane 목록 조회
43
+ */
44
+ listPanes(): Promise<{
45
+ id: string;
46
+ index: number;
47
+ active: boolean;
48
+ cwd: string;
49
+ }[]>;
50
+ /**
51
+ * pane 종료
52
+ */
53
+ killPane(paneId: string): Promise<void>;
54
+ /**
55
+ * pane에 키 전송
56
+ */
57
+ sendKeys(paneId: string, keys: string): Promise<void>;
58
+ /**
59
+ * pane에 특수 키 전송 (C-l, C-c, Enter 등 tmux 키 이름)
60
+ */
61
+ sendSpecialKey(paneId: string, keyName: string): Promise<void>;
62
+ /**
63
+ * pane에 Enter 키 전송
64
+ */
65
+ sendEnter(paneId: string): Promise<void>;
66
+ /**
67
+ * 현재 window의 레이아웃 설정
68
+ * @param layout 'even-horizontal' | 'even-vertical' | 'main-horizontal' | 'main-vertical' | 'tiled'
69
+ */
70
+ setLayout(layout: string): Promise<void>;
71
+ /**
72
+ * pane 크기 조정
73
+ */
74
+ resizePane(paneId: string, direction: 'U' | 'D' | 'L' | 'R', amount: number): Promise<void>;
75
+ /**
76
+ * pane 너비를 절대값으로 설정
77
+ */
78
+ setPaneWidth(paneId: string, width: number): Promise<void>;
79
+ /**
80
+ * pane을 별도 window로 분리 (백그라운드 실행 유지)
81
+ * @returns 새로 생성된 window ID
82
+ */
83
+ breakPaneToWindow(paneId: string): Promise<string>;
84
+ /**
85
+ * 특정 session:index에 window 생성
86
+ * @returns 새로 생성된 window ID
87
+ */
88
+ createWindowAtIndex(sessionName: string, index: number, cwd: string): Promise<string>;
89
+ /**
90
+ * 숨겨진 window 생성 (단일 pane)
91
+ */
92
+ createHiddenWindow(cwd?: string): Promise<string>;
93
+ /**
94
+ * window의 pane을 특정 pane과 swap
95
+ */
96
+ swapPaneWithWindow(windowId: string, targetPaneId: string): Promise<void>;
97
+ /**
98
+ * window 내 단일 pane 너비 설정
99
+ */
100
+ setWindowPaneWidth(windowId: string, width: number): Promise<void>;
101
+ /**
102
+ * pane index로 pane ID 조회 (현재 window)
103
+ */
104
+ getPaneIdByIndex(index: number): Promise<string | null>;
105
+ /**
106
+ * 숨겨진 window에서 pane을 현재 window로 가져옴
107
+ * @param windowId 숨겨진 window ID
108
+ * @param targetPaneId 옆에 배치할 target pane
109
+ * @returns 가져온 pane의 새 ID
110
+ */
111
+ joinPaneFromWindow(windowId: string, targetPaneId: string): Promise<string>;
112
+ /**
113
+ * pane 숨기기 (width=0) - deprecated, use breakPaneToWindow
114
+ */
115
+ hidePane(paneId: string): Promise<void>;
116
+ /**
117
+ * pane 표시 (지정 너비로 복원) - deprecated, use joinPaneFromWindow
118
+ */
119
+ showPane(paneId: string, width: number): Promise<void>;
120
+ /**
121
+ * 현재 window 너비 조회
122
+ */
123
+ getWindowWidth(): Promise<number>;
124
+ /**
125
+ * pane 너비 조회
126
+ */
127
+ getPaneWidth(paneId: string): Promise<number>;
128
+ /**
129
+ * pane 높이 조회
130
+ */
131
+ getPaneHeight(paneId: string): Promise<number>;
132
+ /**
133
+ * 현재 세션 이름 조회
134
+ */
135
+ getSessionName(): Promise<string | null>;
136
+ /**
137
+ * 현재 pane ID 조회
138
+ */
139
+ getCurrentPaneId(): Promise<string | null>;
140
+ /**
141
+ * UX 개선 설정 적용
142
+ * - 마우스 모드 활성화 (클릭 선택, 드래그 리사이징)
143
+ * - 활성 pane 테두리 강조
144
+ * - pane swap 단축키 (Ctrl+b m)
145
+ */
146
+ applyUXSettings(): Promise<void>;
147
+ /**
148
+ * 대시보드 pane 리사이즈 훅 설정
149
+ */
150
+ setDashboardResizeHook(paneId: string, width: number): Promise<void>;
151
+ /**
152
+ * main-vertical 레이아웃 적용 (왼쪽 고정, 오른쪽 분할)
153
+ * @param mainWidth 왼쪽 메인 pane 너비 (columns)
154
+ */
155
+ applyMainVerticalLayout(mainWidth?: number): Promise<void>;
156
+ /**
157
+ * 특정 pane 기준으로 분할
158
+ * @param targetPaneId 분할할 대상 pane
159
+ * @param direction 'v' = 수직 (좌우), 'h' = 수평 (상하)
160
+ * @param cwd 새 pane의 작업 디렉토리
161
+ */
162
+ splitPane(targetPaneId: string, direction: 'v' | 'h', cwd?: string): Promise<string>;
163
+ /**
164
+ * 현재 세션 종료
165
+ */
166
+ killCurrentSession(): Promise<void>;
167
+ /**
168
+ * 현재 클라이언트 detach (세션은 유지)
169
+ */
170
+ detachClient(): Promise<void>;
171
+ /**
172
+ * Detach client and kill a window in one atomic tmux command.
173
+ * Prevents flash of another window between kill and detach.
174
+ */
175
+ detachAndKillWindow(sessionName: string, windowIndex: number): Promise<void>;
176
+ /**
177
+ * 특정 window 종료
178
+ */
179
+ killWindow(windowId: string): Promise<void>;
180
+ /**
181
+ * pane 화면 클리어 (scrollback 포함)
182
+ */
183
+ clearPane(paneId: string): Promise<void>;
184
+ /**
185
+ * 클라이언트 강제 리프레시
186
+ */
187
+ refreshClient(): Promise<void>;
188
+ /**
189
+ * pane 위치 swap
190
+ * @param paneId 이동할 pane
191
+ * @param direction 'left' | 'right' | 'up' | 'down'
192
+ */
193
+ swapPane(paneId: string, direction: 'left' | 'right' | 'up' | 'down'): Promise<void>;
194
+ /**
195
+ * 대시보드 제외하고 오른쪽 pane들 균등 분할
196
+ * @param dashPaneId 대시보드 pane ID
197
+ * @param dashWidth 대시보드 너비 (columns)
198
+ */
199
+ distributeRightPanes(dashPaneId: string, dashWidth?: number): Promise<void>;
200
+ /**
201
+ * 현재 세션의 모든 window 목록 조회
202
+ */
203
+ listWindows(): Promise<{
204
+ id: string;
205
+ index: number;
206
+ name: string;
207
+ cwd: string;
208
+ active: boolean;
209
+ }[]>;
210
+ /**
211
+ * 특정 window로 포커스 전환
212
+ */
213
+ selectWindow(windowId: string): Promise<void>;
214
+ /**
215
+ * 새 window 생성
216
+ * @param cwd 작업 디렉토리 (옵션)
217
+ * @param name window 이름 (옵션)
218
+ * @returns 생성된 window ID
219
+ */
220
+ createNewWindow(cwd?: string, name?: string): Promise<string>;
221
+ /**
222
+ * 현재 window ID 조회
223
+ */
224
+ getCurrentWindowId(): Promise<string | null>;
225
+ /**
226
+ * 현재 window index 조회
227
+ */
228
+ getCurrentWindowIndex(): Promise<number | null>;
229
+ /**
230
+ * window 이름 변경
231
+ */
232
+ renameWindow(windowId: string, name: string): Promise<void>;
233
+ }