vibecodingmachine-core 2026.3.9-907 → 2026.3.10-1547
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 +1 -1
- package/src/auth/access-denied.html +119 -119
- package/src/auth/shared-auth-storage.js +267 -267
- package/src/autonomous-mode/feature-implementer.cjs +70 -70
- package/src/autonomous-mode/feature-implementer.js +425 -425
- package/src/beta-request.js +160 -160
- package/src/chat-management/chat-manager.cjs +71 -71
- package/src/chat-management/chat-manager.js +342 -342
- package/src/compliance/compliance-prompt.js +183 -183
- package/src/ide-integration/aider-cli-manager.cjs +850 -850
- package/src/ide-integration/applescript-manager.cjs +3215 -3215
- package/src/ide-integration/applescript-utils.js +314 -314
- package/src/ide-integration/cdp-manager.cjs +221 -221
- package/src/ide-integration/claude-code-cli-manager.cjs +456 -456
- package/src/ide-integration/cline-cli-manager.cjs +2252 -2252
- package/src/ide-integration/continue-cli-manager.js +431 -431
- package/src/ide-integration/provider-manager.cjs +595 -595
- package/src/ide-integration/quota-detector.cjs +399 -399
- package/src/ide-integration/windows-automation-manager.js +532 -4
- package/src/ide-integration/windows-ide-manager.js +12 -3
- package/src/index.cjs +142 -142
- package/src/llm/direct-llm-manager.cjs +1299 -1299
- package/src/localization/index.js +147 -147
- package/src/quota-management/index.js +108 -108
- package/src/requirement-numbering.js +164 -164
- package/src/sync/aws-setup.js +445 -445
- package/src/ui/ButtonComponents.js +247 -247
- package/src/ui/ChatInterface.js +499 -499
- package/src/ui/StateManager.js +259 -259
- package/src/utils/audit-logger.cjs +116 -116
- package/src/utils/config-helpers.cjs +94 -94
- package/src/utils/config-helpers.js +94 -94
- package/src/utils/env-helpers.js +54 -54
- package/src/utils/error-reporter.js +117 -117
- package/src/utils/gcloud-auth.cjs +394 -394
- package/src/utils/git-branch-manager.js +278 -278
- package/src/utils/logger.cjs +193 -193
- package/src/utils/logger.js +191 -191
- package/src/utils/repo-helpers.cjs +120 -120
- package/src/utils/repo-helpers.js +120 -120
- package/src/utils/update-checker.js +246 -246
- package/src/utils/version-checker.js +170 -170
package/src/utils/env-helpers.js
CHANGED
|
@@ -1,54 +1,54 @@
|
|
|
1
|
-
const path = require('path');
|
|
2
|
-
const fs = require('fs');
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* Check if running in development environment
|
|
6
|
-
* @returns {boolean} True if in development
|
|
7
|
-
*/
|
|
8
|
-
function isDevelopment() {
|
|
9
|
-
// Check standard environment variables
|
|
10
|
-
if (process.env.NODE_ENV === 'development' ||
|
|
11
|
-
process.env.VIBECODINGMACHINE_ENV === 'development' ||
|
|
12
|
-
process.env.ELECTRON_IS_DEV === '1') {
|
|
13
|
-
return true;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
// Check for --dev flag in arguments
|
|
17
|
-
if (process.argv.includes('--dev')) {
|
|
18
|
-
return true;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
// Heuristics for local development
|
|
22
|
-
// 1. Check if we are in a git repository that looks like the source code
|
|
23
|
-
// Root of the monorepo usually has 'packages' directory and 'lerna.json' or 'pnpm-workspace.yaml'
|
|
24
|
-
// But this might be too aggressive if user installs via git clone.
|
|
25
|
-
|
|
26
|
-
// 2. Check if electron is running from default app (not packaged)
|
|
27
|
-
if (process.versions && process.versions.electron) {
|
|
28
|
-
const electron = require('electron');
|
|
29
|
-
if (electron.app && !electron.app.isPackaged) {
|
|
30
|
-
return true;
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
return false;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
/**
|
|
38
|
-
* Check if we should perform update checks
|
|
39
|
-
* @returns {boolean} True if update checks are allowed
|
|
40
|
-
*/
|
|
41
|
-
function shouldCheckUpdates() {
|
|
42
|
-
// Don't check updates in development unless explicitly forced (not implemented yet)
|
|
43
|
-
if (isDevelopment()) {
|
|
44
|
-
return false;
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
// Can add more logic here (e.g. disable updates via config)
|
|
48
|
-
return true;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
module.exports = {
|
|
52
|
-
isDevelopment,
|
|
53
|
-
shouldCheckUpdates
|
|
54
|
-
};
|
|
1
|
+
const path = require('path');
|
|
2
|
+
const fs = require('fs');
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Check if running in development environment
|
|
6
|
+
* @returns {boolean} True if in development
|
|
7
|
+
*/
|
|
8
|
+
function isDevelopment() {
|
|
9
|
+
// Check standard environment variables
|
|
10
|
+
if (process.env.NODE_ENV === 'development' ||
|
|
11
|
+
process.env.VIBECODINGMACHINE_ENV === 'development' ||
|
|
12
|
+
process.env.ELECTRON_IS_DEV === '1') {
|
|
13
|
+
return true;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
// Check for --dev flag in arguments
|
|
17
|
+
if (process.argv.includes('--dev')) {
|
|
18
|
+
return true;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
// Heuristics for local development
|
|
22
|
+
// 1. Check if we are in a git repository that looks like the source code
|
|
23
|
+
// Root of the monorepo usually has 'packages' directory and 'lerna.json' or 'pnpm-workspace.yaml'
|
|
24
|
+
// But this might be too aggressive if user installs via git clone.
|
|
25
|
+
|
|
26
|
+
// 2. Check if electron is running from default app (not packaged)
|
|
27
|
+
if (process.versions && process.versions.electron) {
|
|
28
|
+
const electron = require('electron');
|
|
29
|
+
if (electron.app && !electron.app.isPackaged) {
|
|
30
|
+
return true;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
return false;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Check if we should perform update checks
|
|
39
|
+
* @returns {boolean} True if update checks are allowed
|
|
40
|
+
*/
|
|
41
|
+
function shouldCheckUpdates() {
|
|
42
|
+
// Don't check updates in development unless explicitly forced (not implemented yet)
|
|
43
|
+
if (isDevelopment()) {
|
|
44
|
+
return false;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
// Can add more logic here (e.g. disable updates via config)
|
|
48
|
+
return true;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
module.exports = {
|
|
52
|
+
isDevelopment,
|
|
53
|
+
shouldCheckUpdates
|
|
54
|
+
};
|
|
@@ -1,117 +1,117 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Global Error Reporter for VibeCodingMachine
|
|
3
|
-
*
|
|
4
|
-
* Automatically reports errors to the admin database for tracking and fixing.
|
|
5
|
-
* This helps the admin know about issues and use VibeCodingMachine to fix itself.
|
|
6
|
-
*/
|
|
7
|
-
|
|
8
|
-
class ErrorReporter {
|
|
9
|
-
constructor() {
|
|
10
|
-
this.enabled = true;
|
|
11
|
-
this.db = null;
|
|
12
|
-
|
|
13
|
-
try {
|
|
14
|
-
const UserDatabase = require('../database/user-schema');
|
|
15
|
-
this.db = new UserDatabase();
|
|
16
|
-
} catch (error) {
|
|
17
|
-
console.warn('ErrorReporter: Failed to initialize UserDatabase:', error.message);
|
|
18
|
-
this.enabled = false;
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
/**
|
|
23
|
-
* Set authentication token for error reporting
|
|
24
|
-
*/
|
|
25
|
-
setAuthToken(token) {
|
|
26
|
-
if (this.db) {
|
|
27
|
-
this.db.setAuthToken(token);
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
/**
|
|
32
|
-
* Enable or disable error reporting
|
|
33
|
-
*/
|
|
34
|
-
setEnabled(enabled) {
|
|
35
|
-
this.enabled = enabled;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
/**
|
|
39
|
-
* Report an error to the admin database
|
|
40
|
-
*/
|
|
41
|
-
async reportError(error, context = {}) {
|
|
42
|
-
if (!this.enabled) {
|
|
43
|
-
return false;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
try {
|
|
47
|
-
const errorData = {
|
|
48
|
-
message: error.message || String(error),
|
|
49
|
-
stack: error.stack || '',
|
|
50
|
-
name: error.name || 'Error',
|
|
51
|
-
code: error.code || '',
|
|
52
|
-
context: {
|
|
53
|
-
...context,
|
|
54
|
-
cwd: process.cwd(),
|
|
55
|
-
argv: process.argv.slice(2).filter(arg =>
|
|
56
|
-
!arg.includes('password') &&
|
|
57
|
-
!arg.includes('token') &&
|
|
58
|
-
!arg.includes('secret')
|
|
59
|
-
)
|
|
60
|
-
}
|
|
61
|
-
};
|
|
62
|
-
|
|
63
|
-
await this.db.reportError(errorData);
|
|
64
|
-
return true;
|
|
65
|
-
} catch (reportError) {
|
|
66
|
-
// Silently fail - don't block the application
|
|
67
|
-
console.warn('Failed to report error:', reportError.message);
|
|
68
|
-
return false;
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
/**
|
|
73
|
-
* Wrap a function to automatically report errors
|
|
74
|
-
*/
|
|
75
|
-
wrapFunction(fn, context = {}) {
|
|
76
|
-
return async (...args) => {
|
|
77
|
-
try {
|
|
78
|
-
return await fn(...args);
|
|
79
|
-
} catch (error) {
|
|
80
|
-
await this.reportError(error, {
|
|
81
|
-
...context,
|
|
82
|
-
functionName: fn.name,
|
|
83
|
-
args: args.filter(arg =>
|
|
84
|
-
typeof arg !== 'object' ||
|
|
85
|
-
!JSON.stringify(arg).match(/password|token|secret/i)
|
|
86
|
-
)
|
|
87
|
-
});
|
|
88
|
-
throw error;
|
|
89
|
-
}
|
|
90
|
-
};
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
/**
|
|
94
|
-
* Create a global error handler for uncaught exceptions
|
|
95
|
-
*/
|
|
96
|
-
setupGlobalHandlers() {
|
|
97
|
-
process.on('uncaughtException', async (error) => {
|
|
98
|
-
await this.reportError(error, {
|
|
99
|
-
type: 'uncaughtException'
|
|
100
|
-
});
|
|
101
|
-
});
|
|
102
|
-
|
|
103
|
-
process.on('unhandledRejection', async (error) => {
|
|
104
|
-
await this.reportError(error, {
|
|
105
|
-
type: 'unhandledRejection'
|
|
106
|
-
});
|
|
107
|
-
});
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
// Singleton instance
|
|
112
|
-
const errorReporter = new ErrorReporter();
|
|
113
|
-
|
|
114
|
-
module.exports = {
|
|
115
|
-
ErrorReporter,
|
|
116
|
-
errorReporter
|
|
117
|
-
};
|
|
1
|
+
/**
|
|
2
|
+
* Global Error Reporter for VibeCodingMachine
|
|
3
|
+
*
|
|
4
|
+
* Automatically reports errors to the admin database for tracking and fixing.
|
|
5
|
+
* This helps the admin know about issues and use VibeCodingMachine to fix itself.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
class ErrorReporter {
|
|
9
|
+
constructor() {
|
|
10
|
+
this.enabled = true;
|
|
11
|
+
this.db = null;
|
|
12
|
+
|
|
13
|
+
try {
|
|
14
|
+
const UserDatabase = require('../database/user-schema');
|
|
15
|
+
this.db = new UserDatabase();
|
|
16
|
+
} catch (error) {
|
|
17
|
+
console.warn('ErrorReporter: Failed to initialize UserDatabase:', error.message);
|
|
18
|
+
this.enabled = false;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* Set authentication token for error reporting
|
|
24
|
+
*/
|
|
25
|
+
setAuthToken(token) {
|
|
26
|
+
if (this.db) {
|
|
27
|
+
this.db.setAuthToken(token);
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* Enable or disable error reporting
|
|
33
|
+
*/
|
|
34
|
+
setEnabled(enabled) {
|
|
35
|
+
this.enabled = enabled;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Report an error to the admin database
|
|
40
|
+
*/
|
|
41
|
+
async reportError(error, context = {}) {
|
|
42
|
+
if (!this.enabled) {
|
|
43
|
+
return false;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
try {
|
|
47
|
+
const errorData = {
|
|
48
|
+
message: error.message || String(error),
|
|
49
|
+
stack: error.stack || '',
|
|
50
|
+
name: error.name || 'Error',
|
|
51
|
+
code: error.code || '',
|
|
52
|
+
context: {
|
|
53
|
+
...context,
|
|
54
|
+
cwd: process.cwd(),
|
|
55
|
+
argv: process.argv.slice(2).filter(arg =>
|
|
56
|
+
!arg.includes('password') &&
|
|
57
|
+
!arg.includes('token') &&
|
|
58
|
+
!arg.includes('secret')
|
|
59
|
+
)
|
|
60
|
+
}
|
|
61
|
+
};
|
|
62
|
+
|
|
63
|
+
await this.db.reportError(errorData);
|
|
64
|
+
return true;
|
|
65
|
+
} catch (reportError) {
|
|
66
|
+
// Silently fail - don't block the application
|
|
67
|
+
console.warn('Failed to report error:', reportError.message);
|
|
68
|
+
return false;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
* Wrap a function to automatically report errors
|
|
74
|
+
*/
|
|
75
|
+
wrapFunction(fn, context = {}) {
|
|
76
|
+
return async (...args) => {
|
|
77
|
+
try {
|
|
78
|
+
return await fn(...args);
|
|
79
|
+
} catch (error) {
|
|
80
|
+
await this.reportError(error, {
|
|
81
|
+
...context,
|
|
82
|
+
functionName: fn.name,
|
|
83
|
+
args: args.filter(arg =>
|
|
84
|
+
typeof arg !== 'object' ||
|
|
85
|
+
!JSON.stringify(arg).match(/password|token|secret/i)
|
|
86
|
+
)
|
|
87
|
+
});
|
|
88
|
+
throw error;
|
|
89
|
+
}
|
|
90
|
+
};
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
/**
|
|
94
|
+
* Create a global error handler for uncaught exceptions
|
|
95
|
+
*/
|
|
96
|
+
setupGlobalHandlers() {
|
|
97
|
+
process.on('uncaughtException', async (error) => {
|
|
98
|
+
await this.reportError(error, {
|
|
99
|
+
type: 'uncaughtException'
|
|
100
|
+
});
|
|
101
|
+
});
|
|
102
|
+
|
|
103
|
+
process.on('unhandledRejection', async (error) => {
|
|
104
|
+
await this.reportError(error, {
|
|
105
|
+
type: 'unhandledRejection'
|
|
106
|
+
});
|
|
107
|
+
});
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
// Singleton instance
|
|
112
|
+
const errorReporter = new ErrorReporter();
|
|
113
|
+
|
|
114
|
+
module.exports = {
|
|
115
|
+
ErrorReporter,
|
|
116
|
+
errorReporter
|
|
117
|
+
};
|