@kandiforge/spectacle 0.3.39 → 0.3.41

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.
Binary file
Binary file
package/bin/kandi-gpt-bin CHANGED
Binary file
Binary file
package/bin/kandi-run-bin CHANGED
Binary file
Binary file
Binary file
Binary file
package/bin/spectacle ADDED
@@ -0,0 +1,25 @@
1
+ #!/usr/bin/env node
2
+
3
+ const { spawn } = require('child_process');
4
+ const path = require('path');
5
+
6
+ // Determine binary name based on platform
7
+ const binaryName = process.platform === 'win32' ? 'kandi-spectacle-bin.exe' : 'kandi-spectacle-bin';
8
+ const binaryPath = path.join(__dirname, binaryName);
9
+
10
+ // Spawn the binary with all arguments
11
+ const child = spawn(binaryPath, process.argv.slice(2), {
12
+ stdio: 'inherit',
13
+ env: process.env
14
+ });
15
+
16
+ // Forward exit code
17
+ child.on('exit', (code) => {
18
+ process.exit(code || 0);
19
+ });
20
+
21
+ // Handle errors
22
+ child.on('error', (err) => {
23
+ console.error('Failed to start spectacle binary:', err.message);
24
+ process.exit(1);
25
+ });
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kandiforge/spectacle",
3
- "version": "0.3.39",
3
+ "version": "0.3.41",
4
4
  "description": "Spectacle server and CLI tools for KandiForge ecosystem",
5
5
  "author": "Abstract Class Consulting Inc.",
6
6
  "license": "PROPRIETARY",
@@ -9,7 +9,7 @@ const stream = require('stream');
9
9
  const pipeline = promisify(stream.pipeline);
10
10
 
11
11
  // This version MUST match package.json
12
- const RELEASE_VERSION = '0.3.39';
12
+ const RELEASE_VERSION = '0.3.41';
13
13
  const GITHUB_REPO = 'KandiForge/distribution';
14
14
 
15
15
  function downloadFile(url, destPath) {
@@ -116,11 +116,12 @@ async function install() {
116
116
  const extractedDir = path.join(binDir, `spectacle-v${RELEASE_VERSION}`);
117
117
 
118
118
  // Move all binaries to the correct location
119
+ // Add -bin suffix so wrapper scripts can call them (wrapper: kandi-plan, binary: kandi-plan-bin)
119
120
  const installedBinaries = [];
120
121
  for (const binaryName of binaries) {
121
122
  const extractedPath = path.join(extractedDir, binaryName);
122
123
 
123
- // Determine destination name: add -bin suffix (spectacle -> spectacle-bin, kandi-plan -> kandi-plan-bin, etc.)
124
+ // Add -bin suffix for the actual binary (wrapper scripts expect this)
124
125
  const baseName = binaryName.replace('.exe', '');
125
126
  const destName = `${baseName}-bin${platform === 'win32' ? '.exe' : ''}`;
126
127
  const binaryPath = path.join(binDir, destName);
@@ -135,7 +136,7 @@ async function install() {
135
136
 
136
137
  installedBinaries.push({ name: baseName, path: binaryPath });
137
138
  } else {
138
- console.warn(`⚠️ Warning: ${binaryName} not found in archive at ${extractedPath}`);
139
+ console.warn(`Warning: ${binaryName} not found in archive at ${extractedPath}`);
139
140
  }
140
141
  }
141
142