makecoder 4.0.66 → 4.0.68
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/cc.mjs +2 -2
- package/dist/coder.js +120 -110
- package/dist/darwin-arm64/cc.js +2 -2
- package/dist/darwin-x64/cc.js +2 -2
- package/dist/linux-x64/cc.js +2 -2
- package/dist/win32-x64/cc.js +2 -2
- package/package.json +8 -8
- package/scripts/postinstall.js +53 -17
package/dist/darwin-arm64/cc.js
CHANGED
|
@@ -23,13 +23,13 @@ var PP4=Object.create;var{getPrototypeOf:WP4,defineProperty:_2H,getOwnPropertyNa
|
|
|
23
23
|
Object.assign(A, {
|
|
24
24
|
post(...args) {
|
|
25
25
|
const [url, payload, ...remainArgs] = args;
|
|
26
|
-
const patchedUrl = url + (url.includes('?') ? '&' : '?') + 'app=codev-cli' + '&version=4.0.
|
|
26
|
+
const patchedUrl = url + (url.includes('?') ? '&' : '?') + 'app=codev-cli' + '&version=4.0.68' + '&session_id=' + S_() + (process.env.SPACE_ID ? '&space_id=' + process.env.SPACE_ID : '');
|
|
27
27
|
if (process.env.CODER_APIKEY) {
|
|
28
28
|
const headerValues = payload.headers.values;
|
|
29
29
|
headerValues.set('AUTHORIZATION', `Bearer ${process.env.CODER_APIKEY}`)
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
-
payload.headers.values.set('X-Coder-Version', '4.0.
|
|
32
|
+
payload.headers.values.set('X-Coder-Version', '4.0.68');
|
|
33
33
|
payload.headers.values.set('X-Coder-Platform', process.platform);
|
|
34
34
|
payload.headers.values.set('X-Coder-Arch', process.arch);
|
|
35
35
|
|
package/dist/darwin-x64/cc.js
CHANGED
|
@@ -23,13 +23,13 @@ var WPK=Object.create;var{getPrototypeOf:GPK,defineProperty:_2H,getOwnPropertyNa
|
|
|
23
23
|
Object.assign(A, {
|
|
24
24
|
post(...args) {
|
|
25
25
|
const [url, payload, ...remainArgs] = args;
|
|
26
|
-
const patchedUrl = url + (url.includes('?') ? '&' : '?') + 'app=codev-cli' + '&version=4.0.
|
|
26
|
+
const patchedUrl = url + (url.includes('?') ? '&' : '?') + 'app=codev-cli' + '&version=4.0.68' + '&session_id=' + S6() + (process.env.SPACE_ID ? '&space_id=' + process.env.SPACE_ID : '');
|
|
27
27
|
if (process.env.CODER_APIKEY) {
|
|
28
28
|
const headerValues = payload.headers.values;
|
|
29
29
|
headerValues.set('AUTHORIZATION', `Bearer ${process.env.CODER_APIKEY}`)
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
-
payload.headers.values.set('X-Coder-Version', '4.0.
|
|
32
|
+
payload.headers.values.set('X-Coder-Version', '4.0.68');
|
|
33
33
|
payload.headers.values.set('X-Coder-Platform', process.platform);
|
|
34
34
|
payload.headers.values.set('X-Coder-Arch', process.arch);
|
|
35
35
|
|
package/dist/linux-x64/cc.js
CHANGED
|
@@ -23,13 +23,13 @@ var MP9=Object.create;var{getPrototypeOf:jP9,defineProperty:qWH,getOwnPropertyNa
|
|
|
23
23
|
Object.assign(A, {
|
|
24
24
|
post(...args) {
|
|
25
25
|
const [url, payload, ...remainArgs] = args;
|
|
26
|
-
const patchedUrl = url + (url.includes('?') ? '&' : '?') + 'app=codev-cli' + '&version=4.0.
|
|
26
|
+
const patchedUrl = url + (url.includes('?') ? '&' : '?') + 'app=codev-cli' + '&version=4.0.68' + '&session_id=' + R$() + (process.env.SPACE_ID ? '&space_id=' + process.env.SPACE_ID : '');
|
|
27
27
|
if (process.env.CODER_APIKEY) {
|
|
28
28
|
const headerValues = payload.headers.values;
|
|
29
29
|
headerValues.set('AUTHORIZATION', `Bearer ${process.env.CODER_APIKEY}`)
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
-
payload.headers.values.set('X-Coder-Version', '4.0.
|
|
32
|
+
payload.headers.values.set('X-Coder-Version', '4.0.68');
|
|
33
33
|
payload.headers.values.set('X-Coder-Platform', process.platform);
|
|
34
34
|
payload.headers.values.set('X-Coder-Arch', process.arch);
|
|
35
35
|
|
package/dist/win32-x64/cc.js
CHANGED
|
@@ -23,13 +23,13 @@ var PJ_=Object.create;var{getPrototypeOf:WJ_,defineProperty:K2H,getOwnPropertyNa
|
|
|
23
23
|
Object.assign(A, {
|
|
24
24
|
post(...args) {
|
|
25
25
|
const [url, payload, ...remainArgs] = args;
|
|
26
|
-
const patchedUrl = url + (url.includes('?') ? '&' : '?') + 'app=codev-cli' + '&version=4.0.
|
|
26
|
+
const patchedUrl = url + (url.includes('?') ? '&' : '?') + 'app=codev-cli' + '&version=4.0.68' + '&session_id=' + R8() + (process.env.SPACE_ID ? '&space_id=' + process.env.SPACE_ID : '');
|
|
27
27
|
if (process.env.CODER_APIKEY) {
|
|
28
28
|
const headerValues = payload.headers.values;
|
|
29
29
|
headerValues.set('AUTHORIZATION', `Bearer ${process.env.CODER_APIKEY}`)
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
-
payload.headers.values.set('X-Coder-Version', '4.0.
|
|
32
|
+
payload.headers.values.set('X-Coder-Version', '4.0.68');
|
|
33
33
|
payload.headers.values.set('X-Coder-Platform', process.platform);
|
|
34
34
|
payload.headers.values.set('X-Coder-Arch', process.arch);
|
|
35
35
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "makecoder",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.68",
|
|
4
4
|
"description": "MakeCoder: Unified AI agent CLI tool integrating Claude Code, Codex and Gemini CLI",
|
|
5
5
|
"main": "./dist/coder.js",
|
|
6
6
|
"bin": {
|
|
@@ -30,16 +30,11 @@
|
|
|
30
30
|
},
|
|
31
31
|
"homepage": "https://github.com/makecoderai/coder",
|
|
32
32
|
"dependencies": {
|
|
33
|
+
"bun": ">=1.3.12",
|
|
33
34
|
"node-fetch": "^3.3.2",
|
|
34
35
|
"open": "^10.1.0",
|
|
35
36
|
"zod": "^3.25.76"
|
|
36
37
|
},
|
|
37
|
-
"optionalDependencies": {
|
|
38
|
-
"bun": ">=1.3.12",
|
|
39
|
-
"makecoder-codex-darwin-arm64": "4.0.66",
|
|
40
|
-
"makecoder-codex-linux-x64": "4.0.66",
|
|
41
|
-
"makecoder-codex-win32-x64": "4.0.66"
|
|
42
|
-
},
|
|
43
38
|
"engines": {
|
|
44
39
|
"node": ">=20.0.0"
|
|
45
40
|
},
|
|
@@ -50,5 +45,10 @@
|
|
|
50
45
|
"dist",
|
|
51
46
|
"packages",
|
|
52
47
|
"scripts/postinstall.js"
|
|
53
|
-
]
|
|
48
|
+
],
|
|
49
|
+
"optionalDependencies": {
|
|
50
|
+
"makecoder-codex-darwin-arm64": "4.0.68",
|
|
51
|
+
"makecoder-codex-linux-x64": "4.0.68",
|
|
52
|
+
"makecoder-codex-win32-x64": "4.0.68"
|
|
53
|
+
}
|
|
54
54
|
}
|
package/scripts/postinstall.js
CHANGED
|
@@ -3,38 +3,75 @@
|
|
|
3
3
|
const fs = require('fs');
|
|
4
4
|
const path = require('path');
|
|
5
5
|
const os = require('os');
|
|
6
|
-
const {
|
|
6
|
+
const { execFileSync } = require('child_process');
|
|
7
|
+
|
|
8
|
+
const PLATFORM_PACKAGES = {
|
|
9
|
+
'darwin-arm64': '@oven-sh/bun-darwin-aarch64',
|
|
10
|
+
'darwin-x64': '@oven-sh/bun-darwin-x64',
|
|
11
|
+
'linux-arm64': '@oven-sh/bun-linux-aarch64',
|
|
12
|
+
'linux-x64': '@oven-sh/bun-linux-x64',
|
|
13
|
+
'win32-x64': '@oven-sh/bun-windows-x64',
|
|
14
|
+
};
|
|
7
15
|
|
|
8
16
|
function isBunAvailable() {
|
|
9
|
-
const
|
|
17
|
+
const isWindows = process.platform === 'win32';
|
|
18
|
+
const binName = isWindows ? 'bun.exe' : 'bun';
|
|
19
|
+
|
|
20
|
+
// 1. PATH
|
|
10
21
|
try {
|
|
11
22
|
execFileSync(binName, ['--version'], { stdio: 'ignore' });
|
|
12
23
|
return true;
|
|
13
24
|
} catch {}
|
|
14
25
|
|
|
15
|
-
//
|
|
16
|
-
|
|
17
|
-
|
|
26
|
+
// 2. require.resolve('bun/bin/bun') — works after `npm install bun`
|
|
27
|
+
// drops the platform package into our own node_modules.
|
|
28
|
+
try {
|
|
29
|
+
const resolved = require.resolve(
|
|
30
|
+
isWindows ? 'bun/bin/bun.exe' : 'bun/bin/bun',
|
|
31
|
+
{ paths: [path.join(__dirname, '..')] },
|
|
32
|
+
);
|
|
33
|
+
if (fs.existsSync(resolved)) return true;
|
|
34
|
+
} catch {}
|
|
35
|
+
|
|
36
|
+
// 3. ~/.bun/bin/bun (curl bun.sh/install fallback location)
|
|
37
|
+
const home = process.env.HOME || process.env.USERPROFILE || '';
|
|
38
|
+
if (home && fs.existsSync(path.join(home, '.bun', 'bin', binName))) {
|
|
18
39
|
return true;
|
|
19
40
|
}
|
|
20
41
|
|
|
21
42
|
return false;
|
|
22
43
|
}
|
|
23
44
|
|
|
45
|
+
function npmCmd() {
|
|
46
|
+
return process.platform === 'win32' ? 'npm.cmd' : 'npm';
|
|
47
|
+
}
|
|
48
|
+
|
|
24
49
|
function installBun() {
|
|
25
|
-
|
|
26
|
-
const
|
|
50
|
+
const platformKey = `${process.platform}-${process.arch}`;
|
|
51
|
+
const platformPkg = PLATFORM_PACKAGES[platformKey];
|
|
52
|
+
if (!platformPkg) {
|
|
53
|
+
console.warn(`⚠️ No bun binary published for ${platformKey}.`);
|
|
54
|
+
console.warn(' Install it manually: npm install -g bun or curl -fsSL https://bun.sh/install | bash');
|
|
55
|
+
return;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
console.log(`bun not found, installing ${platformPkg} via npm...`);
|
|
59
|
+
const installDir = path.join(__dirname, '..');
|
|
27
60
|
|
|
61
|
+
// Install into makecoder's own node_modules so _resolveBunPath()'s
|
|
62
|
+
// require.resolve('bun/bin/bun') and the @oven-sh fallback can find it.
|
|
63
|
+
// --no-save avoids polluting the lockfile of an enclosing project when
|
|
64
|
+
// makecoder is installed locally; --no-audit/--no-fund make it quiet.
|
|
28
65
|
try {
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
66
|
+
execFileSync(
|
|
67
|
+
npmCmd(),
|
|
68
|
+
['install', '--no-save', '--no-audit', '--no-fund', `bun@latest`, platformPkg],
|
|
69
|
+
{ cwd: installDir, stdio: 'inherit' },
|
|
70
|
+
);
|
|
34
71
|
console.log('bun installed successfully.');
|
|
35
72
|
} catch (error) {
|
|
36
73
|
console.warn('⚠️ Failed to auto-install bun:', error.message);
|
|
37
|
-
console.warn('
|
|
74
|
+
console.warn(' Install it manually: npm install -g bun or curl -fsSL https://bun.sh/install | bash');
|
|
38
75
|
}
|
|
39
76
|
}
|
|
40
77
|
|
|
@@ -45,12 +82,12 @@ function copyRecursive(src, dest) {
|
|
|
45
82
|
}
|
|
46
83
|
|
|
47
84
|
const stats = fs.statSync(src);
|
|
48
|
-
|
|
85
|
+
|
|
49
86
|
if (stats.isDirectory()) {
|
|
50
87
|
if (!fs.existsSync(dest)) {
|
|
51
88
|
fs.mkdirSync(dest, { recursive: true });
|
|
52
89
|
}
|
|
53
|
-
|
|
90
|
+
|
|
54
91
|
const items = fs.readdirSync(src);
|
|
55
92
|
items.forEach(item => {
|
|
56
93
|
const srcPath = path.join(src, item);
|
|
@@ -62,7 +99,7 @@ function copyRecursive(src, dest) {
|
|
|
62
99
|
if (!fs.existsSync(destDir)) {
|
|
63
100
|
fs.mkdirSync(destDir, { recursive: true });
|
|
64
101
|
}
|
|
65
|
-
|
|
102
|
+
|
|
66
103
|
// Force overwrite existing files
|
|
67
104
|
try {
|
|
68
105
|
fs.copyFileSync(src, dest);
|
|
@@ -101,7 +138,6 @@ function main() {
|
|
|
101
138
|
|
|
102
139
|
copyRecursive(coderSrcDir, coderDestDir);
|
|
103
140
|
console.log('Successfully copied configuration files to ~/.coder (existing files overwritten)');
|
|
104
|
-
|
|
105
141
|
} catch (error) {
|
|
106
142
|
console.error('Error during postinstall setup:', error.message);
|
|
107
143
|
process.exit(1);
|