diffwatch 1.1.2 → 2.0.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.
- package/LICENSE +21 -0
- package/README.md +115 -47
- package/bin/diffwatch.js +30 -0
- package/dist/diffwatch.exe +0 -0
- package/package.json +67 -29
- package/AGENTS.md +0 -201
- package/dist/index.d.ts +0 -2
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js +0 -605
- package/dist/index.js.map +0 -1
- package/dist/utils/diff-formatter.d.ts +0 -1
- package/dist/utils/diff-formatter.js +0 -108
- package/dist/utils/diff-formatter.js.map +0 -1
- package/dist/utils/git.d.ts +0 -16
- package/dist/utils/git.d.ts.map +0 -1
- package/dist/utils/git.js +0 -196
- package/dist/utils/git.js.map +0 -1
- package/jest.config.js +0 -11
- package/screenshot.jpg +0 -0
- package/src/index.ts +0 -640
- package/src/utils/diff-formatter.ts +0 -81
- package/src/utils/git.ts +0 -185
- package/tests/git.test.d.ts +0 -2
- package/tests/git.test.d.ts.map +0 -1
- package/tests/git.test.js.map +0 -1
- package/tests/git.test.ts +0 -148
- package/tsconfig.json +0 -16
package/dist/index.js
DELETED
|
@@ -1,605 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
"use strict";
|
|
3
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
4
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
5
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
6
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
7
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
8
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
9
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
10
|
-
});
|
|
11
|
-
};
|
|
12
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
13
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
14
|
-
};
|
|
15
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
const blessed = require('neo-neo-blessed');
|
|
17
|
-
const chalk_1 = __importDefault(require("chalk"));
|
|
18
|
-
const child_process_1 = require("child_process");
|
|
19
|
-
const git_1 = require("./utils/git");
|
|
20
|
-
const diff_formatter_1 = require("./utils/diff-formatter");
|
|
21
|
-
const fs_1 = require("fs");
|
|
22
|
-
const path_1 = require("path");
|
|
23
|
-
const packageJson = JSON.parse((0, fs_1.readFileSync)((0, path_1.join)((0, path_1.dirname)(__filename), '..', 'package.json'), 'utf-8'));
|
|
24
|
-
function main() {
|
|
25
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
26
|
-
const args = process.argv.slice(2);
|
|
27
|
-
let repoPath = process.cwd();
|
|
28
|
-
const showHelp = () => {
|
|
29
|
-
console.log(`
|
|
30
|
-
Usage: diffwatch [path]
|
|
31
|
-
|
|
32
|
-
Arguments:
|
|
33
|
-
path Path to the git repository (default: current directory)
|
|
34
|
-
|
|
35
|
-
Options:
|
|
36
|
-
-h, --help Show help information
|
|
37
|
-
-v, --version Show version information
|
|
38
|
-
`);
|
|
39
|
-
process.exit(0);
|
|
40
|
-
};
|
|
41
|
-
const showVersion = () => {
|
|
42
|
-
console.log(`diffwatch v${packageJson.version}`);
|
|
43
|
-
process.exit(0);
|
|
44
|
-
};
|
|
45
|
-
const positionalArgs = [];
|
|
46
|
-
for (let i = 0; i < args.length; i++) {
|
|
47
|
-
if (args[i] === '-h' || args[i] === '--help') {
|
|
48
|
-
showHelp();
|
|
49
|
-
}
|
|
50
|
-
else if (args[i] === '-v' || args[i] === '--version') {
|
|
51
|
-
showVersion();
|
|
52
|
-
}
|
|
53
|
-
else if (args[i].startsWith('-')) {
|
|
54
|
-
// Ignore unknown flags or handle them if needed
|
|
55
|
-
}
|
|
56
|
-
else {
|
|
57
|
-
positionalArgs.push(args[i]);
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
if (positionalArgs.length > 0) {
|
|
61
|
-
repoPath = positionalArgs[0];
|
|
62
|
-
}
|
|
63
|
-
try {
|
|
64
|
-
process.chdir(repoPath);
|
|
65
|
-
}
|
|
66
|
-
catch (err) {
|
|
67
|
-
console.error(`Error: Could not change directory to ${repoPath}`);
|
|
68
|
-
process.exit(1);
|
|
69
|
-
}
|
|
70
|
-
const gitHandler = new git_1.GitHandler(repoPath);
|
|
71
|
-
if (!(yield gitHandler.isRepo())) {
|
|
72
|
-
console.log(chalk_1.default.red(`Error: ${repoPath} is not a git repository.`));
|
|
73
|
-
process.exit(1);
|
|
74
|
-
}
|
|
75
|
-
// Force xterm-256color to encourage better mouse support on Windows terminals
|
|
76
|
-
if (process.platform === 'win32' && !process.env.TERM) {
|
|
77
|
-
process.env.TERM = 'xterm-256color';
|
|
78
|
-
}
|
|
79
|
-
const screen = blessed.screen({
|
|
80
|
-
smartCSR: true,
|
|
81
|
-
title: 'diffwatch',
|
|
82
|
-
mouse: true,
|
|
83
|
-
});
|
|
84
|
-
// Explicitly enable mouse tracking
|
|
85
|
-
screen.program.enableMouse();
|
|
86
|
-
let fileList = blessed.list({
|
|
87
|
-
top: 0,
|
|
88
|
-
left: 0,
|
|
89
|
-
width: '30%',
|
|
90
|
-
height: '99%',
|
|
91
|
-
label: 'Files (0)',
|
|
92
|
-
keys: true,
|
|
93
|
-
vi: true,
|
|
94
|
-
mouse: true,
|
|
95
|
-
tags: true,
|
|
96
|
-
scrollbar: {
|
|
97
|
-
ch: ' ',
|
|
98
|
-
track: { bg: 'white' },
|
|
99
|
-
style: { bg: 'blue' },
|
|
100
|
-
},
|
|
101
|
-
style: {
|
|
102
|
-
selected: { fg: 'black', bg: 'white' },
|
|
103
|
-
border: { fg: 'white' },
|
|
104
|
-
},
|
|
105
|
-
border: { type: 'line' },
|
|
106
|
-
});
|
|
107
|
-
const createFileList = () => {
|
|
108
|
-
const newList = blessed.list({
|
|
109
|
-
top: 0,
|
|
110
|
-
left: 0,
|
|
111
|
-
width: '30%',
|
|
112
|
-
height: '99%',
|
|
113
|
-
label: 'Files (0)',
|
|
114
|
-
keys: true,
|
|
115
|
-
vi: true,
|
|
116
|
-
mouse: true,
|
|
117
|
-
tags: true,
|
|
118
|
-
scrollbar: {
|
|
119
|
-
ch: ' ',
|
|
120
|
-
track: { bg: 'white' },
|
|
121
|
-
style: { bg: 'blue' },
|
|
122
|
-
},
|
|
123
|
-
style: {
|
|
124
|
-
selected: { fg: 'black', bg: 'white' },
|
|
125
|
-
border: { fg: 'white' },
|
|
126
|
-
},
|
|
127
|
-
border: { type: 'line' },
|
|
128
|
-
});
|
|
129
|
-
newList.on('select item', () => {
|
|
130
|
-
scheduleDiffUpdate();
|
|
131
|
-
});
|
|
132
|
-
newList.key(['up', 'down'], () => {
|
|
133
|
-
scheduleDiffUpdate();
|
|
134
|
-
});
|
|
135
|
-
newList.on('wheeldown', () => handleScroll('down'));
|
|
136
|
-
newList.on('wheelup', () => handleScroll('up'));
|
|
137
|
-
return newList;
|
|
138
|
-
};
|
|
139
|
-
const diffView = blessed.scrollabletext({
|
|
140
|
-
top: 0,
|
|
141
|
-
left: '30%',
|
|
142
|
-
width: '70%',
|
|
143
|
-
height: '99%',
|
|
144
|
-
label: ' Diff () ',
|
|
145
|
-
keys: true,
|
|
146
|
-
vi: true,
|
|
147
|
-
mouse: true,
|
|
148
|
-
scrollbar: {
|
|
149
|
-
ch: ' ',
|
|
150
|
-
track: { bg: 'white' },
|
|
151
|
-
style: { bg: 'blue' },
|
|
152
|
-
},
|
|
153
|
-
style: {
|
|
154
|
-
border: { fg: 'white' },
|
|
155
|
-
},
|
|
156
|
-
border: { type: 'line' },
|
|
157
|
-
tags: false,
|
|
158
|
-
});
|
|
159
|
-
const searchBox = blessed.box({
|
|
160
|
-
top: 'center',
|
|
161
|
-
left: '40%', // Center of right pane (30% + 70%/2 = 65%)
|
|
162
|
-
width: '50%',
|
|
163
|
-
height: 3,
|
|
164
|
-
label: ' Search ',
|
|
165
|
-
border: { type: 'line' },
|
|
166
|
-
style: { border: { fg: 'yellow' } },
|
|
167
|
-
hidden: true,
|
|
168
|
-
});
|
|
169
|
-
const searchInput = blessed.textbox({
|
|
170
|
-
parent: searchBox,
|
|
171
|
-
top: 0,
|
|
172
|
-
left: 0,
|
|
173
|
-
width: '100%-2',
|
|
174
|
-
height: 1,
|
|
175
|
-
keys: true,
|
|
176
|
-
inputOnFocus: true,
|
|
177
|
-
style: { fg: 'white', bg: 'black' },
|
|
178
|
-
});
|
|
179
|
-
// Confirmation dialog for revert
|
|
180
|
-
const confirmDialog = blessed.box({
|
|
181
|
-
top: 'center',
|
|
182
|
-
left: '45%', // Center of right pane (30% + 70%/2 = 65%)
|
|
183
|
-
width: '38%',
|
|
184
|
-
label: ' Confirm Revert ',
|
|
185
|
-
height: 3,
|
|
186
|
-
content: 'Press SPACE key to confirm revert or ESC to cancel.',
|
|
187
|
-
border: { type: 'line' },
|
|
188
|
-
style: {
|
|
189
|
-
fg: 'yellow',
|
|
190
|
-
bg: 'black',
|
|
191
|
-
border: { fg: 'yellow' }
|
|
192
|
-
},
|
|
193
|
-
hidden: true,
|
|
194
|
-
});
|
|
195
|
-
const notificationBox = blessed.box({
|
|
196
|
-
top: 'center',
|
|
197
|
-
left: '45%', // Center of right pane (30% + 70%/2 = 65%)
|
|
198
|
-
width: '38%',
|
|
199
|
-
height: 3,
|
|
200
|
-
label: ' Notification ',
|
|
201
|
-
border: { type: 'line' },
|
|
202
|
-
style: {
|
|
203
|
-
fg: 'green',
|
|
204
|
-
bg: 'black',
|
|
205
|
-
border: { fg: 'green' }
|
|
206
|
-
},
|
|
207
|
-
hidden: true,
|
|
208
|
-
});
|
|
209
|
-
const showNotification = (message, color = 'green') => {
|
|
210
|
-
const previouslyFocused = screen.focused;
|
|
211
|
-
notificationBox.setContent(message);
|
|
212
|
-
notificationBox.style = {
|
|
213
|
-
fg: color,
|
|
214
|
-
bg: 'black',
|
|
215
|
-
border: { fg: color }
|
|
216
|
-
};
|
|
217
|
-
notificationBox.show();
|
|
218
|
-
notificationBox.setFront();
|
|
219
|
-
screen.render();
|
|
220
|
-
setTimeout(() => {
|
|
221
|
-
notificationBox.hide();
|
|
222
|
-
if (previouslyFocused && previouslyFocused !== notificationBox) {
|
|
223
|
-
previouslyFocused.focus();
|
|
224
|
-
}
|
|
225
|
-
else {
|
|
226
|
-
fileList.focus();
|
|
227
|
-
}
|
|
228
|
-
updateBorders();
|
|
229
|
-
screen.render();
|
|
230
|
-
}, 3000);
|
|
231
|
-
};
|
|
232
|
-
// Branch display in bottom right
|
|
233
|
-
const branchBox = blessed.box({
|
|
234
|
-
bottom: 0,
|
|
235
|
-
right: 0,
|
|
236
|
-
width: 'shrink',
|
|
237
|
-
height: 1,
|
|
238
|
-
align: 'left',
|
|
239
|
-
content: chalk_1.default.cyan('Branch: '),
|
|
240
|
-
style: {
|
|
241
|
-
fg: 'white',
|
|
242
|
-
},
|
|
243
|
-
});
|
|
244
|
-
// Footer box to show shortcuts - aligned with the panes
|
|
245
|
-
const footer = blessed.box({
|
|
246
|
-
bottom: 0,
|
|
247
|
-
left: 0,
|
|
248
|
-
width: '100%',
|
|
249
|
-
height: 1,
|
|
250
|
-
content: chalk_1.default.green('←→') + ' Switch |' + chalk_1.default.green(' ⏎') + ' Open | ' + chalk_1.default.green('S') + ' Search | ' + chalk_1.default.green('R') + ' Revert | ' + chalk_1.default.green('Q') + ' Quit ',
|
|
251
|
-
});
|
|
252
|
-
screen.append(fileList);
|
|
253
|
-
screen.append(diffView);
|
|
254
|
-
screen.append(searchBox);
|
|
255
|
-
screen.append(notificationBox);
|
|
256
|
-
screen.append(confirmDialog);
|
|
257
|
-
screen.append(footer);
|
|
258
|
-
screen.append(branchBox);
|
|
259
|
-
const updateBorders = () => {
|
|
260
|
-
fileList.style.border.fg = screen.focused === fileList ? 'yellow' : 'white';
|
|
261
|
-
diffView.style.border.fg = screen.focused === diffView ? 'yellow' : 'white';
|
|
262
|
-
screen.render();
|
|
263
|
-
};
|
|
264
|
-
let currentFiles = [];
|
|
265
|
-
let lastSelectedPath = null;
|
|
266
|
-
let diffUpdateTimeout = null;
|
|
267
|
-
let currentSearchTerm = '';
|
|
268
|
-
let currentBranch = '';
|
|
269
|
-
let lastFilePaths = [];
|
|
270
|
-
let isUpdatingList = false;
|
|
271
|
-
const scheduleDiffUpdate = () => {
|
|
272
|
-
if (diffUpdateTimeout)
|
|
273
|
-
clearTimeout(diffUpdateTimeout);
|
|
274
|
-
diffUpdateTimeout = setTimeout(() => __awaiter(this, void 0, void 0, function* () {
|
|
275
|
-
yield updateDiff();
|
|
276
|
-
}), 150); // 150ms debounce
|
|
277
|
-
};
|
|
278
|
-
const handleScroll = (direction) => {
|
|
279
|
-
const focused = screen.focused;
|
|
280
|
-
if (focused === fileList) {
|
|
281
|
-
if (direction === 'up') {
|
|
282
|
-
focused.up(1);
|
|
283
|
-
}
|
|
284
|
-
else {
|
|
285
|
-
focused.down(1);
|
|
286
|
-
}
|
|
287
|
-
scheduleDiffUpdate();
|
|
288
|
-
screen.render();
|
|
289
|
-
}
|
|
290
|
-
else if (focused === diffView) {
|
|
291
|
-
const scrollAmount = direction === 'up' ? -2 : 2;
|
|
292
|
-
diffView.scroll(scrollAmount);
|
|
293
|
-
screen.render();
|
|
294
|
-
}
|
|
295
|
-
};
|
|
296
|
-
// Remove default wheel listeners to enforce "scroll focused only" behavior
|
|
297
|
-
fileList.removeAllListeners('wheeldown');
|
|
298
|
-
fileList.removeAllListeners('wheelup');
|
|
299
|
-
diffView.removeAllListeners('wheeldown');
|
|
300
|
-
diffView.removeAllListeners('wheelup');
|
|
301
|
-
// Attach custom scroll handlers to widgets (captures wheel even if hovering specific widget)
|
|
302
|
-
// We use widget-level listeners now that screen.mouse is true.
|
|
303
|
-
// We attach to both to ensure the event is caught regardless of where the mouse is.
|
|
304
|
-
// We use widget-level listeners now that screen.mouse is true.
|
|
305
|
-
// We attach to both to ensure the event is caught regardless of where the mouse is.
|
|
306
|
-
// The handleScroll function will then decide WHAT to scroll based on focus.
|
|
307
|
-
diffView.on('wheeldown', () => handleScroll('down'));
|
|
308
|
-
diffView.on('wheelup', () => handleScroll('up'));
|
|
309
|
-
// Also listen on screen for events that might miss the widgets (margins, borders)
|
|
310
|
-
screen.on('wheeldown', () => handleScroll('down'));
|
|
311
|
-
screen.on('wheelup', () => handleScroll('up'));
|
|
312
|
-
const openInEditor = (filePath) => {
|
|
313
|
-
try {
|
|
314
|
-
if (process.platform === 'win32') {
|
|
315
|
-
// On Windows, use 'start' to open with default program
|
|
316
|
-
(0, child_process_1.spawn)('cmd', ['/c', 'start', '', filePath], { stdio: 'ignore', detached: true }).unref();
|
|
317
|
-
}
|
|
318
|
-
else {
|
|
319
|
-
// On Unix-like systems, try EDITOR, fallback to xdg-open
|
|
320
|
-
const editor = process.env.EDITOR || process.env.VISUAL || 'xdg-open';
|
|
321
|
-
(0, child_process_1.spawn)(editor, [filePath], { stdio: 'ignore', detached: true }).unref();
|
|
322
|
-
}
|
|
323
|
-
}
|
|
324
|
-
catch (error) {
|
|
325
|
-
console.error(`Failed to open ${filePath}: ${error}`);
|
|
326
|
-
}
|
|
327
|
-
};
|
|
328
|
-
const updateBranch = () => __awaiter(this, void 0, void 0, function* () {
|
|
329
|
-
const branch = yield gitHandler.getBranch();
|
|
330
|
-
if (branch !== currentBranch) {
|
|
331
|
-
currentBranch = branch;
|
|
332
|
-
branchBox.setContent(chalk_1.default.cyan('Branch: ') + chalk_1.default.yellow(branch));
|
|
333
|
-
screen.render();
|
|
334
|
-
}
|
|
335
|
-
});
|
|
336
|
-
const updateDiff = () => __awaiter(this, void 0, void 0, function* () {
|
|
337
|
-
const selectedIndex = fileList.selected;
|
|
338
|
-
const selectedFile = currentFiles[selectedIndex];
|
|
339
|
-
if (!selectedFile) {
|
|
340
|
-
// No valid file selected, clear diff view
|
|
341
|
-
diffView.setContent('Select a file to view diff.');
|
|
342
|
-
diffView.setLabel(' Diff () ');
|
|
343
|
-
lastSelectedPath = null;
|
|
344
|
-
screen.render();
|
|
345
|
-
return;
|
|
346
|
-
}
|
|
347
|
-
if (selectedFile) {
|
|
348
|
-
let content = '';
|
|
349
|
-
let label = ` Diff (${selectedFile.path}) `;
|
|
350
|
-
if (selectedFile.status !== 'unchanged' && selectedFile.status !== 'deleted') {
|
|
351
|
-
const diff = yield gitHandler.getDiff(selectedFile.path);
|
|
352
|
-
content = (0, diff_formatter_1.formatDiffWithDiff2Html)(diff, currentSearchTerm);
|
|
353
|
-
}
|
|
354
|
-
if (!content && selectedFile.status !== 'deleted') {
|
|
355
|
-
content = yield gitHandler.getFileContent(selectedFile.path);
|
|
356
|
-
// Highlight search term in full content
|
|
357
|
-
if (currentSearchTerm) {
|
|
358
|
-
const regex = new RegExp(`(${currentSearchTerm.replace(/[.*+?^${}()|[\]\\]/g, '\\$&')})`, 'gi');
|
|
359
|
-
content = content.replace(regex, `\x1b[43m\x1b[30m$1\x1b[0m`);
|
|
360
|
-
}
|
|
361
|
-
label = ` File (${selectedFile.path}) `;
|
|
362
|
-
}
|
|
363
|
-
else if (!content && selectedFile.status === 'deleted') {
|
|
364
|
-
content = chalk_1.default.red('File was deleted.');
|
|
365
|
-
label = ` Diff (${selectedFile.path}) `;
|
|
366
|
-
}
|
|
367
|
-
const currentContent = diffView.content;
|
|
368
|
-
const currentLabel = diffView.label;
|
|
369
|
-
// Only update if content or label changed to reduce flickering
|
|
370
|
-
if (content !== currentContent || label !== currentLabel) {
|
|
371
|
-
const savedScroll = diffView.scrollTop;
|
|
372
|
-
const isNewFile = selectedFile.path !== lastSelectedPath;
|
|
373
|
-
diffView.setContent(content);
|
|
374
|
-
diffView.setLabel(label);
|
|
375
|
-
if (isNewFile) {
|
|
376
|
-
diffView.scrollTo(0);
|
|
377
|
-
}
|
|
378
|
-
else {
|
|
379
|
-
diffView.scrollTop = savedScroll;
|
|
380
|
-
}
|
|
381
|
-
}
|
|
382
|
-
lastSelectedPath = selectedFile.path;
|
|
383
|
-
}
|
|
384
|
-
else {
|
|
385
|
-
const newContent = 'Select a file to view diff.';
|
|
386
|
-
const newLabel = ' Diff () ';
|
|
387
|
-
if (diffView.content !== newContent || diffView.label !== newLabel) {
|
|
388
|
-
diffView.setContent(newContent);
|
|
389
|
-
diffView.setLabel(newLabel);
|
|
390
|
-
diffView.scrollTo(0);
|
|
391
|
-
}
|
|
392
|
-
lastSelectedPath = null;
|
|
393
|
-
}
|
|
394
|
-
screen.render();
|
|
395
|
-
});
|
|
396
|
-
const updateFileList = () => __awaiter(this, void 0, void 0, function* () {
|
|
397
|
-
var _a;
|
|
398
|
-
if (isUpdatingList)
|
|
399
|
-
return;
|
|
400
|
-
isUpdatingList = true;
|
|
401
|
-
const selectedPath = (_a = currentFiles[fileList.selected]) === null || _a === void 0 ? void 0 : _a.path;
|
|
402
|
-
let files;
|
|
403
|
-
if (currentSearchTerm) {
|
|
404
|
-
files = yield gitHandler.searchFiles(currentSearchTerm);
|
|
405
|
-
}
|
|
406
|
-
else {
|
|
407
|
-
files = yield gitHandler.getStatus();
|
|
408
|
-
}
|
|
409
|
-
currentFiles = files;
|
|
410
|
-
const items = files.map((f) => {
|
|
411
|
-
let color = '{white-fg}';
|
|
412
|
-
if (f.status === 'added')
|
|
413
|
-
color = '{green-fg}';
|
|
414
|
-
else if (f.status === 'deleted')
|
|
415
|
-
color = '{red-fg}';
|
|
416
|
-
else if (f.status === 'modified')
|
|
417
|
-
color = '{blue-fg}';
|
|
418
|
-
else if (f.status === 'unstaged')
|
|
419
|
-
color = '{green-fg}';
|
|
420
|
-
else if (f.status === 'unchanged')
|
|
421
|
-
color = '{grey-fg}';
|
|
422
|
-
let statusSymbol = '';
|
|
423
|
-
if (f.status === 'added')
|
|
424
|
-
statusSymbol = 'A ';
|
|
425
|
-
else if (f.status === 'deleted')
|
|
426
|
-
statusSymbol = 'D ';
|
|
427
|
-
else if (f.status === 'modified')
|
|
428
|
-
statusSymbol = 'M ';
|
|
429
|
-
else if (f.status === 'unstaged')
|
|
430
|
-
statusSymbol = '+ ';
|
|
431
|
-
else if (f.status === 'unchanged')
|
|
432
|
-
statusSymbol = ' ';
|
|
433
|
-
return `${color}${statusSymbol}${f.path}{/}`;
|
|
434
|
-
});
|
|
435
|
-
const labelTitle = currentSearchTerm ? `Files (${files.length}) - Searching: "${currentSearchTerm}"` : `Files (${files.length})`;
|
|
436
|
-
const newFilePaths = files.map(f => f.path);
|
|
437
|
-
const selectedFileStillExists = selectedPath ? newFilePaths.includes(selectedPath) : false;
|
|
438
|
-
const listChanged = lastFilePaths.length !== newFilePaths.length ||
|
|
439
|
-
lastFilePaths.some(path => !newFilePaths.includes(path)) ||
|
|
440
|
-
newFilePaths.some(path => !lastFilePaths.includes(path));
|
|
441
|
-
if (items.length > 0) {
|
|
442
|
-
const newSelectedIndex = selectedPath ? currentFiles.findIndex(f => f.path === selectedPath) : -1;
|
|
443
|
-
const oldFileList = fileList;
|
|
444
|
-
const newFileList = createFileList();
|
|
445
|
-
newFileList.setLabel(labelTitle);
|
|
446
|
-
newFileList.setItems(items);
|
|
447
|
-
newFileList.select(newSelectedIndex >= 0 ? newSelectedIndex : 0);
|
|
448
|
-
if (!selectedFileStillExists || listChanged) {
|
|
449
|
-
lastSelectedPath = null;
|
|
450
|
-
}
|
|
451
|
-
lastFilePaths = newFilePaths;
|
|
452
|
-
if (diffUpdateTimeout) {
|
|
453
|
-
clearTimeout(diffUpdateTimeout);
|
|
454
|
-
diffUpdateTimeout = null;
|
|
455
|
-
}
|
|
456
|
-
yield updateDiff();
|
|
457
|
-
oldFileList.destroy();
|
|
458
|
-
screen.remove(oldFileList);
|
|
459
|
-
fileList = newFileList;
|
|
460
|
-
screen.append(fileList);
|
|
461
|
-
}
|
|
462
|
-
else {
|
|
463
|
-
const oldFileList = fileList;
|
|
464
|
-
const newFileList = createFileList();
|
|
465
|
-
newFileList.setLabel(labelTitle);
|
|
466
|
-
newFileList.setItems([]);
|
|
467
|
-
diffView.setContent(currentSearchTerm ? `No files match "${currentSearchTerm}".` : 'No changes detected.');
|
|
468
|
-
diffView.setLabel(' Diff () ');
|
|
469
|
-
lastSelectedPath = null;
|
|
470
|
-
lastFilePaths = [];
|
|
471
|
-
oldFileList.destroy();
|
|
472
|
-
screen.remove(oldFileList);
|
|
473
|
-
fileList = newFileList;
|
|
474
|
-
screen.append(fileList);
|
|
475
|
-
}
|
|
476
|
-
screen.render();
|
|
477
|
-
isUpdatingList = false;
|
|
478
|
-
});
|
|
479
|
-
screen.key(['s'], () => {
|
|
480
|
-
searchBox.show();
|
|
481
|
-
searchBox.setFront();
|
|
482
|
-
searchInput.setValue(currentSearchTerm);
|
|
483
|
-
searchInput.focus();
|
|
484
|
-
screen.render();
|
|
485
|
-
});
|
|
486
|
-
searchInput.on('submit', (value) => __awaiter(this, void 0, void 0, function* () {
|
|
487
|
-
currentSearchTerm = (value || '').trim();
|
|
488
|
-
searchBox.hide();
|
|
489
|
-
fileList.focus();
|
|
490
|
-
// Force immediate update
|
|
491
|
-
yield updateFileList();
|
|
492
|
-
}));
|
|
493
|
-
searchInput.on('cancel', () => {
|
|
494
|
-
searchBox.hide();
|
|
495
|
-
fileList.focus();
|
|
496
|
-
screen.render();
|
|
497
|
-
});
|
|
498
|
-
screen.key(['tab'], () => {
|
|
499
|
-
if (screen.focused === fileList) {
|
|
500
|
-
diffView.focus();
|
|
501
|
-
}
|
|
502
|
-
else {
|
|
503
|
-
fileList.focus();
|
|
504
|
-
}
|
|
505
|
-
updateBorders();
|
|
506
|
-
});
|
|
507
|
-
screen.key(['left'], () => {
|
|
508
|
-
if (screen.focused !== fileList) {
|
|
509
|
-
fileList.focus();
|
|
510
|
-
updateBorders();
|
|
511
|
-
}
|
|
512
|
-
});
|
|
513
|
-
screen.key(['right'], () => {
|
|
514
|
-
if (screen.focused !== diffView) {
|
|
515
|
-
diffView.focus();
|
|
516
|
-
updateBorders();
|
|
517
|
-
}
|
|
518
|
-
});
|
|
519
|
-
screen.key(['enter'], () => {
|
|
520
|
-
const selectedIndex = fileList.selected;
|
|
521
|
-
const selectedFile = currentFiles[selectedIndex];
|
|
522
|
-
if (selectedFile) {
|
|
523
|
-
openInEditor(selectedFile.path);
|
|
524
|
-
}
|
|
525
|
-
});
|
|
526
|
-
// Handle revert key press
|
|
527
|
-
screen.key(['r'], () => __awaiter(this, void 0, void 0, function* () {
|
|
528
|
-
const selectedIndex = fileList.selected;
|
|
529
|
-
const selectedFile = currentFiles[selectedIndex];
|
|
530
|
-
if (selectedFile) {
|
|
531
|
-
confirmDialog.show();
|
|
532
|
-
confirmDialog.setFront();
|
|
533
|
-
confirmDialog.focus();
|
|
534
|
-
screen.render();
|
|
535
|
-
}
|
|
536
|
-
}));
|
|
537
|
-
// Handle dialog keys
|
|
538
|
-
confirmDialog.key(['space'], () => __awaiter(this, void 0, void 0, function* () {
|
|
539
|
-
const selectedIndex = fileList.selected;
|
|
540
|
-
const selectedFile = currentFiles[selectedIndex];
|
|
541
|
-
if (selectedFile) {
|
|
542
|
-
try {
|
|
543
|
-
yield gitHandler.revertFile(selectedFile.path);
|
|
544
|
-
showNotification(`File ${selectedFile.path} reverted successfully.`, 'green');
|
|
545
|
-
yield updateFileList();
|
|
546
|
-
}
|
|
547
|
-
catch (error) {
|
|
548
|
-
const errorMessage = error instanceof Error ? error.message : String(error);
|
|
549
|
-
showNotification(`Error reverting file: ${errorMessage}`, 'red');
|
|
550
|
-
}
|
|
551
|
-
}
|
|
552
|
-
confirmDialog.hide();
|
|
553
|
-
fileList.focus();
|
|
554
|
-
screen.render();
|
|
555
|
-
}));
|
|
556
|
-
confirmDialog.key(['escape'], () => {
|
|
557
|
-
confirmDialog.hide();
|
|
558
|
-
fileList.focus();
|
|
559
|
-
screen.render();
|
|
560
|
-
});
|
|
561
|
-
yield updateBranch();
|
|
562
|
-
yield updateFileList();
|
|
563
|
-
fileList.focus();
|
|
564
|
-
updateBorders();
|
|
565
|
-
// Set up periodic updates to detect new git changes
|
|
566
|
-
const updateInterval = setInterval(() => __awaiter(this, void 0, void 0, function* () {
|
|
567
|
-
const currentlyFocused = screen.focused;
|
|
568
|
-
const wasFileListFocused = currentlyFocused === fileList;
|
|
569
|
-
yield updateBranch();
|
|
570
|
-
yield updateFileList();
|
|
571
|
-
// Restore focus to the same pane it was on before the update
|
|
572
|
-
if (wasFileListFocused) {
|
|
573
|
-
fileList.focus();
|
|
574
|
-
}
|
|
575
|
-
else if (currentlyFocused === diffView) {
|
|
576
|
-
diffView.focus();
|
|
577
|
-
}
|
|
578
|
-
updateBorders();
|
|
579
|
-
}), 2000); // Check for changes every 2 seconds
|
|
580
|
-
// Clean up interval on exit
|
|
581
|
-
screen.key(['escape', 'q', 'C-c'], () => {
|
|
582
|
-
// Don't handle ESC if confirmation dialog has focus or is visible
|
|
583
|
-
if (screen.focused === confirmDialog || !confirmDialog.hidden) {
|
|
584
|
-
return false;
|
|
585
|
-
}
|
|
586
|
-
if (!searchBox.hidden) {
|
|
587
|
-
searchBox.hide();
|
|
588
|
-
screen.render();
|
|
589
|
-
fileList.focus();
|
|
590
|
-
return false;
|
|
591
|
-
}
|
|
592
|
-
else {
|
|
593
|
-
// Clear interval only when actually exiting
|
|
594
|
-
clearInterval(updateInterval);
|
|
595
|
-
screen.destroy();
|
|
596
|
-
process.exit(0);
|
|
597
|
-
}
|
|
598
|
-
});
|
|
599
|
-
});
|
|
600
|
-
}
|
|
601
|
-
main().catch(err => {
|
|
602
|
-
console.error(err);
|
|
603
|
-
process.exit(1);
|
|
604
|
-
});
|
|
605
|
-
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AACA,MAAM,OAAO,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC;AAC3C,kDAA0B;AAC1B,iDAAsC;AACtC,qCAAqD;AACrD,2D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