codebuff 1.0.523 → 1.0.524
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 +3 -2
- package/postinstall.js +34 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "codebuff",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.524",
|
|
4
4
|
"description": "AI coding agent",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"bin": {
|
|
@@ -8,11 +8,12 @@
|
|
|
8
8
|
"cb": "index.js"
|
|
9
9
|
},
|
|
10
10
|
"scripts": {
|
|
11
|
-
"postinstall": "node
|
|
11
|
+
"postinstall": "node postinstall.js",
|
|
12
12
|
"preuninstall": "node -e \"const fs = require('fs'); const path = require('path'); const os = require('os'); const binaryPath = path.join(os.homedir(), '.config', 'manicode', process.platform === 'win32' ? 'codebuff.exe' : 'codebuff'); try { fs.unlinkSync(binaryPath) } catch (e) { /* ignore if file doesn't exist */ }\""
|
|
13
13
|
},
|
|
14
14
|
"files": [
|
|
15
15
|
"index.js",
|
|
16
|
+
"postinstall.js",
|
|
16
17
|
"README.md"
|
|
17
18
|
],
|
|
18
19
|
"os": [
|
package/postinstall.js
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const fs = require('fs');
|
|
4
|
+
const path = require('path');
|
|
5
|
+
const os = require('os');
|
|
6
|
+
|
|
7
|
+
// Clean up old binary
|
|
8
|
+
const binaryPath = path.join(
|
|
9
|
+
os.homedir(),
|
|
10
|
+
'.config',
|
|
11
|
+
'manicode',
|
|
12
|
+
process.platform === 'win32' ? 'codebuff.exe' : 'codebuff'
|
|
13
|
+
);
|
|
14
|
+
|
|
15
|
+
try {
|
|
16
|
+
fs.unlinkSync(binaryPath);
|
|
17
|
+
} catch (e) {
|
|
18
|
+
/* ignore if file doesn't exist */
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
// Print welcome message
|
|
22
|
+
console.log('\n');
|
|
23
|
+
console.log('🎉 Welcome to Codebuff!');
|
|
24
|
+
console.log('\n');
|
|
25
|
+
console.log('To get started:');
|
|
26
|
+
console.log(' 1. cd to your project directory');
|
|
27
|
+
console.log(' 2. Run: codebuff');
|
|
28
|
+
console.log('\n');
|
|
29
|
+
console.log('Example:');
|
|
30
|
+
console.log(' $ cd ~/my-project');
|
|
31
|
+
console.log(' $ codebuff');
|
|
32
|
+
console.log('\n');
|
|
33
|
+
console.log('For more information, visit: https://codebuff.com/docs');
|
|
34
|
+
console.log('\n');
|