codeep 1.0.115 → 1.0.117
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/dist/components/Help.js +3 -1
- package/dist/index.js +30 -3
- package/package.json +1 -1
package/dist/components/Help.js
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Text, Box } from 'ink';
|
|
3
|
-
export const Help = () =>
|
|
3
|
+
export const Help = () => {
|
|
4
|
+
return (_jsxs(Box, { flexDirection: "column", children: [_jsx(Text, { color: "#f02a30", bold: true, children: "Available Commands" }), _jsx(Text, { children: " " }), _jsxs(Box, { flexDirection: "row", gap: 2, children: [_jsxs(Box, { flexDirection: "column", flexGrow: 1, children: [_jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/help" }), " - Show this help"] }), _jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/status" }), " - Current status"] }), _jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/settings" }), " - Adjust settings"] }), _jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/sessions" }), " - Manage sessions"] }), _jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/grant" }), " - Grant permissions"] }), _jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/agent" }), " ", '<task>', " - Run agent"] }), _jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/clear" }), " - Clear chat"] })] }), _jsxs(Box, { flexDirection: "column", flexGrow: 1, children: [_jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/model" }), " - Switch model"] }), _jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/provider" }), " - Switch provider"] }), _jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/diff" }), " - Review git changes"] }), _jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/commit" }), " - Generate commit msg"] }), _jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/export" }), " - Export chat"] }), _jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/copy" }), " [n] - Copy code block"] }), _jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", children: "/exit" }), " - Quit"] })] })] }), _jsx(Text, { children: " " }), _jsx(Text, { color: "cyan", children: "Type / to see autocomplete. Docs: github.com/VladoIvankovic/Codeep" })] }));
|
|
5
|
+
};
|
package/dist/index.js
CHANGED
|
@@ -32,7 +32,34 @@ Contact: info@codeep.dev
|
|
|
32
32
|
`);
|
|
33
33
|
process.exit(0);
|
|
34
34
|
}
|
|
35
|
-
//
|
|
36
|
-
|
|
35
|
+
// Enter alternate screen buffer (like vim, less, htop)
|
|
36
|
+
// This isolates the app from terminal scroll history
|
|
37
|
+
// Eliminates ghost content and jumping issues
|
|
38
|
+
process.stdout.write('\x1b[?1049h'); // Enter alternate buffer
|
|
39
|
+
process.stdout.write('\x1b[H'); // Move cursor to top-left
|
|
40
|
+
// Exit alternate buffer on app exit
|
|
41
|
+
const exitAlternateBuffer = () => {
|
|
42
|
+
process.stdout.write('\x1b[?1049l'); // Exit alternate buffer
|
|
43
|
+
};
|
|
44
|
+
// Handle various exit scenarios
|
|
45
|
+
process.on('exit', exitAlternateBuffer);
|
|
46
|
+
process.on('SIGINT', () => {
|
|
47
|
+
exitAlternateBuffer();
|
|
48
|
+
process.exit(0);
|
|
49
|
+
});
|
|
50
|
+
process.on('SIGTERM', () => {
|
|
51
|
+
exitAlternateBuffer();
|
|
52
|
+
process.exit(0);
|
|
53
|
+
});
|
|
54
|
+
// Also handle uncaught exceptions to ensure clean exit
|
|
55
|
+
process.on('uncaughtException', (err) => {
|
|
56
|
+
exitAlternateBuffer();
|
|
57
|
+
console.error('Uncaught Exception:', err);
|
|
58
|
+
process.exit(1);
|
|
59
|
+
});
|
|
37
60
|
// Render app
|
|
38
|
-
render(_jsx(App, {}));
|
|
61
|
+
const { unmount, waitUntilExit } = render(_jsx(App, {}));
|
|
62
|
+
// Ensure alternate buffer is exited when Ink unmounts
|
|
63
|
+
waitUntilExit().then(() => {
|
|
64
|
+
exitAlternateBuffer();
|
|
65
|
+
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "codeep",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.117",
|
|
4
4
|
"description": "AI-powered coding assistant built for the terminal. Multiple LLM providers, project-aware context, and a seamless development workflow.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|