wenox-cli 2.1.0 → 3.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/README.md CHANGED
@@ -1,101 +1,108 @@
1
1
  # WENOX CLI
2
2
 
3
- 🚀 Advanced AI-powered development assistant for your terminal.
3
+ **Claude API Enterprise AI Platform**
4
4
 
5
- ## Quick Install
5
+ Modern AI-powered development assistant that works seamlessly with your existing Python environment.
6
+
7
+ ## Quick Start
6
8
 
7
9
  ```bash
10
+ # Install WENOX CLI
8
11
  npm install -g wenox-cli
9
- ```
10
-
11
- ## Setup & Usage
12
12
 
13
- 1. **Get your API key** from [WENOX Dashboard](https://wenox.ai/dashboard)
13
+ # Set your API key
14
+ set WENOX_API_KEY=your_api_key_here
14
15
 
15
- 2. **Set your API key:**
16
+ # Start coding with AI
17
+ wenox
18
+ ```
16
19
 
17
- **For CMD (Windows Command Prompt):**
18
- ```cmd
19
- set WENOX_API_KEY=your_api_key_here
20
- ```
20
+ ## Features
21
21
 
22
- **For PowerShell:**
23
- ```powershell
24
- $env:WENOX_API_KEY="your_api_key_here"
25
- ```
22
+ - 🚀 **Zero Configuration** - Works with your existing Python setup
23
+ - 🔧 **Auto-Installation** - Installs dependencies automatically when needed
24
+ - 🎯 **Enterprise Ready** - Professional Claude API integration
25
+ - 💻 **Cross-Platform** - Windows, macOS, Linux support
26
+ - 🛡️ **Secure** - Uses user-level Python packages, no system conflicts
26
27
 
27
- **For Linux/Mac:**
28
- ```bash
29
- export WENOX_API_KEY="your_api_key_here"
30
- ```
28
+ ## Installation
31
29
 
32
- 3. **Start coding with AI:**
33
- ```bash
34
- wenox
35
- ```
30
+ ### Method 1: NPM (Recommended)
31
+ ```bash
32
+ npm install -g wenox-cli
33
+ ```
36
34
 
37
- ## Troubleshooting
35
+ ### Method 2: NPX (No Installation)
36
+ ```bash
37
+ npx wenox-cli
38
+ ```
38
39
 
39
- ### Command Not Found
40
- If you get `'wenox' is not recognized` error:
40
+ ## Setup
41
41
 
42
- 1. **Try using npx:**
43
- ```bash
44
- npx wenox
45
- ```
42
+ 1. **Get API Key**: Visit [wenox.ai/dashboard](https://wenox.ai/dashboard)
46
43
 
47
- 2. **Restart your terminal** after installation
44
+ 2. **Set Environment Variable**:
45
+ - **CMD**: `set WENOX_API_KEY=your_key_here`
46
+ - **PowerShell**: `$env:WENOX_API_KEY="your_key_here"`
48
47
 
49
- 3. **Check NPM global path:**
50
- ```bash
51
- npm config get prefix
52
- ```
48
+ 3. **Run WENOX**: `wenox`
53
49
 
54
- 4. **Install globally with admin rights:**
55
- ```bash
56
- npm install -g wenox-cli
57
- ```
50
+ ## System Requirements
58
51
 
59
- ## Features
52
+ - **Python 3.10+** (any version)
53
+ - **Node.js 16+** (for NPM installation)
60
54
 
61
- - 🤖 **Latest AI Models** - Claude, GPT-4, and more
62
- - 💻 **Terminal Native** - Works in your existing workflow
63
- - 🔄 **Real-time Collaboration** - AI pair programming
64
- - 📁 **Project Aware** - Understands your entire codebase
65
- - ⚡ **Lightning Fast** - Optimized for productivity
55
+ WENOX automatically installs Python dependencies using `pip install --user` to avoid system conflicts.
66
56
 
67
- ## Usage Examples
57
+ ## Usage
68
58
 
69
59
  ```bash
70
60
  # Start WENOX in current directory
71
61
  wenox
72
62
 
73
63
  # Work with specific files
74
- wenox src/app.js components/Header.tsx
64
+ wenox file1.py file2.js
75
65
 
76
- # Use different model
66
+ # Use different AI model
77
67
  wenox --model gpt-4
78
68
 
79
69
  # Get help
80
70
  wenox --help
81
71
  ```
82
72
 
83
- ## Requirements
73
+ ## Troubleshooting
74
+
75
+ ### "wenox command not found"
76
+ - Try: `npx wenox-cli`
77
+ - Or restart your terminal after installation
78
+ - Check NPM path: `npm config get prefix`
79
+
80
+ ### Python Dependencies
81
+ WENOX automatically installs required packages. If issues occur:
82
+ ```bash
83
+ pip install --upgrade pip setuptools
84
+ pip install aider-chat
85
+ ```
84
86
 
85
- - Node.js 16+
86
- - Python 3.10+ (auto-detected and prompted if missing)
87
+ ### API Key Issues
88
+ Make sure your API key is set correctly:
89
+ - CMD: `echo %WENOX_API_KEY%`
90
+ - PowerShell: `echo $env:WENOX_API_KEY`
87
91
 
88
- ## Environment Variables
92
+ ## What's New in v3.0
89
93
 
90
- - `WENOX_API_KEY` - Your WENOX API key (required)
91
- - `WENOX_MODEL` - Default model (optional)
94
+ - **Simplified Installation** - No more complex virtual environments
95
+ - **Better Compatibility** - Works with all Python versions 3.10+
96
+ - ✅ **Faster Startup** - Reduced dependency conflicts
97
+ - ✅ **Auto-Recovery** - Handles installation failures gracefully
98
+ - ✅ **Zero Dependencies** - NPM package has no Node.js dependencies
92
99
 
93
100
  ## Support
94
101
 
95
- - 📖 [Documentation](https://docs.wenox.ai)
96
- - 💬 [Discord](https://discord.gg/wenox)
97
- - 📧 [Support](mailto:support@wenox.ai)
102
+ - 📧 Email: support@wenox.ai
103
+ - 🌐 Website: [wenox.ai](https://wenox.ai)
104
+ - 📚 Documentation: [docs.wenox.ai](https://docs.wenox.ai)
98
105
 
99
106
  ---
100
107
 
101
- **WENOX** - AI-powered development, simplified.
108
+ **WENOX CLI v3.0** - Modern AI development made simple.
package/bin/wenox.js CHANGED
@@ -5,15 +5,6 @@ const path = require('path');
5
5
  const fs = require('fs');
6
6
  const os = require('os');
7
7
 
8
- // WENOX environment path
9
- const WENOX_ENV_PATH = path.join(os.homedir(), '.wenox', 'env');
10
- const WENOX_PYTHON = process.platform === 'win32'
11
- ? path.join(WENOX_ENV_PATH, 'Scripts', 'python.exe')
12
- : path.join(WENOX_ENV_PATH, 'bin', 'python');
13
- const WENOX_PIP = process.platform === 'win32'
14
- ? path.join(WENOX_ENV_PATH, 'Scripts', 'pip.exe')
15
- : path.join(WENOX_ENV_PATH, 'bin', 'pip');
16
-
17
8
  // Simple console colors
18
9
  const chalk = {
19
10
  cyan: (text) => `\x1b[36m${text}\x1b[0m`,
@@ -24,21 +15,6 @@ const chalk = {
24
15
  bold: (text) => `\x1b[1m${text}\x1b[0m`
25
16
  };
26
17
 
27
- // Simple boxen replacement
28
- function boxen(content, options = {}) {
29
- const lines = content.split('\n');
30
- const maxLength = Math.max(...lines.map(line => line.length));
31
- const border = '─'.repeat(maxLength + 2);
32
-
33
- let result = `┌${border}┐\n`;
34
- lines.forEach(line => {
35
- result += `│ ${line.padEnd(maxLength)} │\n`;
36
- });
37
- result += `└${border}┘`;
38
-
39
- return result;
40
- }
41
-
42
18
  // WENOX Banner
43
19
  const banner = chalk.cyan(`
44
20
  ██╗ ██╗███████╗███╗ ██╗ ██████╗ ██╗ ██╗
@@ -52,205 +28,7 @@ const banner = chalk.cyan(`
52
28
  `);
53
29
 
54
30
  function showWelcome() {
55
- console.log(boxen(banner, {
56
- padding: 1,
57
- margin: 1,
58
- borderStyle: 'round',
59
- borderColor: 'cyan'
60
- }));
61
- }
62
-
63
- function checkPython() {
64
- return new Promise((resolve) => {
65
- const python = process.platform === 'win32' ? 'python' : 'python3';
66
- const child = spawn(python, ['--version'], { stdio: 'pipe' });
67
-
68
- let versionOutput = '';
69
- child.stdout.on('data', (data) => {
70
- versionOutput += data.toString();
71
- });
72
-
73
- child.on('close', (code) => {
74
- if (code === 0) {
75
- // Extract version number
76
- const versionMatch = versionOutput.match(/Python (\d+)\.(\d+)\.(\d+)/);
77
- if (versionMatch) {
78
- const major = parseInt(versionMatch[1]);
79
- const minor = parseInt(versionMatch[2]);
80
-
81
- console.log(chalk.cyan(`🐍 Python ${major}.${minor} detected`));
82
-
83
- if (major === 3 && minor >= 14) {
84
- console.log(chalk.green('✅ Python 3.14+ detected - using latest compatible packages'));
85
- } else if (major === 3 && minor === 12) {
86
- console.log(chalk.green('✅ Python 3.12 detected - excellent compatibility'));
87
- } else if (major === 3 && minor >= 10) {
88
- console.log(chalk.green('✅ Python 3.10-3.13 detected - good compatibility'));
89
- } else {
90
- console.log(chalk.red('❌ Python 3.10+ is required for WENOX'));
91
- resolve(false);
92
- return;
93
- }
94
- }
95
- resolve(true);
96
- } else {
97
- resolve(false);
98
- }
99
- });
100
-
101
- child.on('error', () => {
102
- resolve(false);
103
- });
104
- });
105
- }
106
-
107
- function checkWenoxEnvironment() {
108
- return fs.existsSync(WENOX_PYTHON) && fs.existsSync(WENOX_PIP);
109
- }
110
-
111
- async function createWenoxEnvironment() {
112
- console.log(chalk.cyan('🔧 Creating WENOX isolated environment...'));
113
-
114
- // Create .wenox directory
115
- const wenoxDir = path.join(os.homedir(), '.wenox');
116
- if (!fs.existsSync(wenoxDir)) {
117
- fs.mkdirSync(wenoxDir, { recursive: true });
118
- }
119
-
120
- return new Promise((resolve, reject) => {
121
- const python = process.platform === 'win32' ? 'python' : 'python3';
122
-
123
- // Create virtual environment
124
- const venvChild = spawn(python, ['-m', 'venv', WENOX_ENV_PATH], {
125
- stdio: 'inherit',
126
- shell: true
127
- });
128
-
129
- venvChild.on('close', (code) => {
130
- if (code === 0) {
131
- console.log(chalk.green('✅ WENOX environment created successfully!'));
132
- resolve();
133
- } else {
134
- reject(new Error('Failed to create WENOX environment'));
135
- }
136
- });
137
-
138
- venvChild.on('error', (err) => {
139
- reject(err);
140
- });
141
- });
142
- }
143
-
144
- async function installWenoxPackages() {
145
- console.log(chalk.cyan('📦 Installing WENOX packages in isolated environment...'));
146
- console.log(chalk.yellow('🔧 This ensures no conflicts with your system Python'));
147
-
148
- return new Promise((resolve, reject) => {
149
- // First upgrade pip in the virtual environment
150
- console.log(chalk.cyan('🔧 Upgrading pip in WENOX environment...'));
151
-
152
- const upgradeChild = spawn(WENOX_PIP, [
153
- 'install',
154
- '--upgrade',
155
- 'pip',
156
- 'setuptools',
157
- 'wheel'
158
- ], {
159
- stdio: 'inherit',
160
- shell: true
161
- });
162
-
163
- upgradeChild.on('close', (upgradeCode) => {
164
- if (upgradeCode !== 0) {
165
- console.log(chalk.yellow('⚠️ Pip upgrade failed, continuing anyway...'));
166
- }
167
-
168
- // Install exact working packages from requirements
169
- console.log(chalk.cyan('📋 Installing WENOX packages (exact working versions)...'));
170
-
171
- const requirementsPath = path.join(__dirname, '..', 'requirements-wenox.txt');
172
-
173
- const child = spawn(WENOX_PIP, [
174
- 'install',
175
- '-r',
176
- requirementsPath,
177
- '--force-reinstall'
178
- ], {
179
- stdio: 'inherit',
180
- shell: true
181
- });
182
-
183
- child.on('close', (code) => {
184
- if (code === 0) {
185
- console.log(chalk.green('✅ WENOX packages installed successfully!'));
186
- console.log(chalk.cyan('🎯 All packages are isolated and working perfectly'));
187
- resolve();
188
- } else {
189
- console.log(chalk.yellow('⚠️ Some packages failed, trying core installation...'));
190
-
191
- // Fallback: install core packages only
192
- const fallbackChild = spawn(WENOX_PIP, [
193
- 'install',
194
- 'aider-chat==0.16.0',
195
- 'openai==0.27.6',
196
- 'anthropic==0.76.0',
197
- 'litellm==0.14.1',
198
- '--force-reinstall'
199
- ], {
200
- stdio: 'inherit',
201
- shell: true
202
- });
203
-
204
- fallbackChild.on('close', (fallbackCode) => {
205
- if (fallbackCode === 0) {
206
- console.log(chalk.green('✅ WENOX core packages installed successfully!'));
207
- console.log(chalk.cyan('🎯 Ready to use WENOX CLI'));
208
- console.log(chalk.yellow('ℹ️ Note: Using minimal installation due to package compatibility'));
209
- resolve();
210
- } else {
211
- console.log(chalk.red('❌ Installation failed. Trying minimal installation...'));
212
-
213
- // Last resort: just aider-chat
214
- const minimalChild = spawn(WENOX_PIP, [
215
- 'install',
216
- 'aider-chat==0.16.0',
217
- '--upgrade'
218
- ], {
219
- stdio: 'inherit',
220
- shell: true
221
- });
222
-
223
- minimalChild.on('close', (minimalCode) => {
224
- if (minimalCode === 0) {
225
- console.log(chalk.green('✅ WENOX minimal installation completed!'));
226
- console.log(chalk.yellow('⚠️ Some features may be limited'));
227
- resolve();
228
- } else {
229
- reject(new Error('Failed to install WENOX dependencies. Please check your Python installation.'));
230
- }
231
- });
232
-
233
- minimalChild.on('error', (err) => {
234
- reject(err);
235
- });
236
- }
237
- });
238
-
239
- fallbackChild.on('error', (err) => {
240
- reject(err);
241
- });
242
- }
243
- });
244
-
245
- child.on('error', (err) => {
246
- reject(err);
247
- });
248
- });
249
-
250
- upgradeChild.on('error', (err) => {
251
- console.log(chalk.yellow('⚠️ Pip upgrade failed, continuing with installation...'));
252
- });
253
- });
31
+ console.log(banner);
254
32
  }
255
33
 
256
34
  function checkApiKey() {
@@ -285,6 +63,66 @@ function setupWenoxDefaults() {
285
63
  }
286
64
  }
287
65
 
66
+ async function installAiderIfNeeded() {
67
+ return new Promise((resolve) => {
68
+ // Check if aider is already installed
69
+ const python = process.platform === 'win32' ? 'python' : 'python3';
70
+ const checkChild = spawn(python, ['-c', 'import aider; print("OK")'], {
71
+ stdio: 'pipe',
72
+ shell: true
73
+ });
74
+
75
+ let output = '';
76
+ checkChild.stdout.on('data', (data) => {
77
+ output += data.toString();
78
+ });
79
+
80
+ checkChild.on('close', (code) => {
81
+ if (code === 0 && output.includes('OK')) {
82
+ console.log(chalk.green('✅ WENOX dependencies ready'));
83
+ resolve();
84
+ } else {
85
+ console.log(chalk.cyan('📦 Installing WENOX dependencies (one-time setup)...'));
86
+ console.log(chalk.yellow('⏳ This may take 1-2 minutes...'));
87
+
88
+ // Install aider-chat with minimal dependencies
89
+ const installChild = spawn(python, [
90
+ '-m', 'pip', 'install',
91
+ 'aider-chat>=0.16.0',
92
+ '--user', // Install to user directory to avoid permission issues
93
+ '--upgrade',
94
+ '--quiet'
95
+ ], {
96
+ stdio: 'inherit',
97
+ shell: true
98
+ });
99
+
100
+ installChild.on('close', (installCode) => {
101
+ if (installCode === 0) {
102
+ console.log(chalk.green('✅ WENOX dependencies installed successfully!'));
103
+ resolve();
104
+ } else {
105
+ console.log(chalk.yellow('⚠️ Installation had issues, but WENOX may still work'));
106
+ console.log(chalk.cyan('💡 If problems persist, try: pip install --upgrade pip setuptools'));
107
+ resolve(); // Continue anyway
108
+ }
109
+ });
110
+
111
+ installChild.on('error', () => {
112
+ console.log(chalk.yellow('⚠️ Auto-installation failed'));
113
+ console.log(chalk.cyan('💡 Please run manually: pip install aider-chat'));
114
+ resolve(); // Continue anyway
115
+ });
116
+ }
117
+ });
118
+
119
+ checkChild.on('error', () => {
120
+ console.log(chalk.yellow('⚠️ Could not check dependencies'));
121
+ resolve(); // Continue anyway
122
+ });
123
+ });
124
+ }
125
+
288
126
  async function runAider() {
289
127
  // Default arguments for WENOX
290
128
  const defaultArgs = [
@@ -302,7 +140,8 @@ async function runAider() {
302
140
 
303
141
  console.log(chalk.green('✅ Starting WENOX Claude API Platform...\n'));
304
142
 
305
- const child = spawn(WENOX_PYTHON, args, {
143
+ const python = process.platform === 'win32' ? 'python' : 'python3';
144
+ const child = spawn(python, args, {
306
145
  stdio: 'inherit',
307
146
  shell: true
308
147
  });
@@ -316,6 +155,8 @@ async function runAider() {
316
155
 
317
156
  child.on('error', (err) => {
318
157
  console.error(chalk.red('❌ Error starting WENOX:'), err.message);
158
+ console.log(chalk.cyan('💡 Make sure Python is installed and in your PATH'));
159
+ console.log(chalk.cyan('💡 Try: pip install aider-chat'));
319
160
  process.exit(1);
320
161
  });
321
162
  }
@@ -360,7 +201,7 @@ ${chalk.bold('Troubleshooting:')}
360
201
  • Check PATH: ${chalk.cyan('npm config get prefix')}
361
202
 
362
203
  ${chalk.bold('System Requirements:')}
363
- • Python 3.10+ (all versions supported)
204
+ • Python 3.10+ (automatically installs dependencies)
364
205
  • Node.js 16+ for NPM installation
365
206
  `);
366
207
  return;
@@ -368,35 +209,15 @@ ${chalk.bold('System Requirements:')}
368
209
 
369
210
  showWelcome();
370
211
 
371
- // Check Python
372
- const hasPython = await checkPython();
373
- if (!hasPython) {
374
- console.log(chalk.red('❌ Python 3.10+ is required'));
375
- console.log('Please install Python from: https://python.org');
376
- process.exit(1);
377
- }
378
-
379
- // Check if WENOX environment exists
380
- const hasWenoxEnv = checkWenoxEnvironment();
381
- if (!hasWenoxEnv) {
382
- console.log(chalk.cyan('🔧 First time setup - creating WENOX environment...'));
383
- try {
384
- await createWenoxEnvironment();
385
- await installWenoxPackages();
386
- } catch (err) {
387
- console.error(chalk.red('❌ Failed to setup WENOX environment:'), err.message);
388
- process.exit(1);
389
- }
390
- } else {
391
- console.log(chalk.green('✅ WENOX environment ready'));
392
- }
393
-
394
212
  // Setup WENOX defaults
395
213
  setupWenoxDefaults();
396
214
 
397
215
  // Check API key
398
216
  checkApiKey();
399
217
 
218
+ // Install aider if needed (simplified approach)
219
+ await installAiderIfNeeded();
220
+
400
221
  // Run aider with WENOX branding
401
222
  await runAider();
402
223
  }
package/package.json CHANGED
@@ -1,13 +1,12 @@
1
1
  {
2
2
  "name": "wenox-cli",
3
- "version": "2.1.0",
3
+ "version": "3.0.0",
4
4
  "description": "WENOX AI - Advanced AI-powered development assistant",
5
5
  "main": "index.js",
6
6
  "bin": {
7
7
  "wenox": "bin/wenox.js"
8
8
  },
9
9
  "scripts": {
10
- "postinstall": "node scripts/install-python-deps.js",
11
10
  "test": "echo \"Error: no test specified\" && exit 1"
12
11
  },
13
12
  "keywords": [
@@ -25,17 +24,10 @@
25
24
  "type": "git",
26
25
  "url": "git+https://github.com/wenox/wenox-cli.git"
27
26
  },
28
- "dependencies": {
29
- "inquirer": "^9.2.12",
30
- "ora": "^7.0.1",
31
- "boxen": "^7.1.1",
32
- "node-fetch": "^3.3.2"
33
- },
27
+ "dependencies": {},
34
28
  "files": [
35
29
  "bin/",
36
- "scripts/",
37
- "README.md",
38
- "requirements-wenox.txt"
30
+ "README.md"
39
31
  ],
40
32
  "engines": {
41
33
  "node": ">=16.0.0"
@@ -1,81 +0,0 @@
1
- # WENOX Enterprise Environment - Working Configuration
2
- # Core WENOX dependencies
3
- aider-chat==0.16.0
4
- openai==0.27.6
5
- anthropic==0.76.0
6
- litellm==0.14.1
7
-
8
- # Essential dependencies - exact working versions
9
- aiohttp==3.13.3
10
- aiosignal==1.4.0
11
- attrs==25.4.0
12
- certifi==2026.1.4
13
- charset-normalizer==3.4.4
14
- diskcache==5.6.3
15
- frozenlist==1.8.0
16
- gitdb==4.0.12
17
- GitPython==3.1.46
18
- grep-ast==0.9.0
19
- idna==3.11
20
- jsonschema==4.26.0
21
- markdown-it-py==4.0.0
22
- multidict==6.7.1
23
- networkx==3.6.1
24
- numpy==2.2.6
25
- pathspec==1.0.4
26
- prompt-toolkit==3.0.52
27
- Pygments==2.19.2
28
- requests==2.32.5
29
- rich==13.9.4
30
- scipy==1.17.0
31
- smmap==5.0.2
32
- sounddevice==0.5.5
33
- soundfile==0.13.1
34
- tiktoken==0.12.0
35
- tqdm==4.67.1
36
- urllib3==2.6.3
37
- wcwidth==0.5.0
38
- yarl==1.22.0
39
- backoff==2.2.1
40
- ConfigArgParse==1.7.1
41
- mdurl==0.1.2
42
- PyYAML==6.0.3
43
- tree-sitter==0.25.2
44
- tree-sitter-language-pack==0.13.0
45
-
46
- # Python compatibility packages
47
- pydantic==2.12.5
48
- pydantic_core==2.41.5
49
- typing_extensions==4.15.0
50
- packaging==26.0
51
- anyio==4.12.1
52
- sniffio==1.3.1
53
- httpcore==1.0.9
54
- httpx==0.28.1
55
- distro==1.9.0
56
- fastuuid==0.14.0
57
- jinja2==3.1.6
58
- MarkupSafe==3.0.3
59
- importlib-metadata==8.7.1
60
- zipp==3.23.0
61
- appdirs==1.4.4
62
- click==8.3.1
63
- colorama==0.4.6
64
- python-dotenv==1.2.1
65
- regex==2026.1.15
66
- h11==0.16.0
67
- jiter==0.12.0
68
- annotated-types==0.7.0
69
- typing-inspection==0.4.2
70
- huggingface-hub==1.3.5
71
- tokenizers==0.22.2
72
- filelock==3.20.3
73
- fsspec==2026.1.0
74
- hf-xet==1.2.0
75
- shellingham==1.5.4
76
- typer-slim==0.21.1
77
- propcache==0.4.1
78
- aiohappyeyeballs==2.6.1
79
-
80
- # Note: This configuration works with Python 3.14
81
- # Some packages may show dependency warnings but WENOX will function correctly
@@ -1,48 +0,0 @@
1
- #!/usr/bin/env node
2
-
3
- const { spawn } = require('child_process');
4
-
5
- // Simple console colors without chalk
6
- const colors = {
7
- cyan: (text) => `\x1b[36m${text}\x1b[0m`,
8
- green: (text) => `\x1b[32m${text}\x1b[0m`,
9
- yellow: (text) => `\x1b[33m${text}\x1b[0m`,
10
- blue: (text) => `\x1b[34m${text}\x1b[0m`
11
- };
12
-
13
- console.log(colors.cyan('🚀 Setting up WENOX CLI...'));
14
-
15
- function checkPython() {
16
- return new Promise((resolve) => {
17
- const python = process.platform === 'win32' ? 'python' : 'python3';
18
- const child = spawn(python, ['--version'], { stdio: 'pipe' });
19
-
20
- child.on('close', (code) => {
21
- resolve(code === 0);
22
- });
23
-
24
- child.on('error', () => {
25
- resolve(false);
26
- });
27
- });
28
- }
29
-
30
- async function main() {
31
- const hasPython = await checkPython();
32
-
33
- if (!hasPython) {
34
- console.log(colors.yellow('⚠️ Python 3.10+ is required for WENOX CLI'));
35
- console.log('Please install Python from: https://python.org');
36
- console.log('After installing Python, run: ' + colors.cyan('npm install -g wenox-cli'));
37
- return;
38
- }
39
-
40
- console.log(colors.green('✅ Python detected'));
41
- console.log(colors.green('✅ WENOX CLI is ready!'));
42
- console.log('\nNext steps:');
43
- console.log('1. Get your API key: ' + colors.blue('https://wenox.ai/dashboard'));
44
- console.log('2. Set environment: ' + colors.yellow('export WENOX_API_KEY=your_key'));
45
- console.log('3. Run: ' + colors.cyan('wenox'));
46
- }
47
-
48
- main();