@wonderwhy-er/desktop-commander 0.2.18-alpha.11 → 0.2.18-alpha.12

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.
@@ -697,11 +697,11 @@ async function restartClaude() {
697
697
  // Main function to export for ESM compatibility
698
698
  export default async function setup() {
699
699
  // VERY FIRST THING - test if stderr works AT ALL
700
- process.stderr.write('\n\n========== SETUP FUNCTION STARTED ==========\n');
701
- process.stderr.write(`__dirname: ${__dirname}\n`);
702
- process.stderr.write(`__filename: ${__filename}\n`);
703
- process.stderr.write(`process.argv: ${JSON.stringify(process.argv)}\n`);
704
- process.stderr.write('=============================================\n\n');
700
+ logToFile('\n\n========== SETUP FUNCTION STARTED ==========\n');
701
+ logToFile(`__dirname: ${__dirname}\n`);
702
+ logToFile(`__filename: ${__filename}\n`);
703
+ logToFile(`process.argv: ${JSON.stringify(process.argv)}\n`);
704
+ logToFile('=============================================\n\n');
705
705
 
706
706
  // Add tracking for setup function entry
707
707
  await trackEvent('npx_setup_function_started');
@@ -802,8 +802,8 @@ export default async function setup() {
802
802
 
803
803
  // Determine if running through npx or locally
804
804
  const isNpx = import.meta.url.includes('node_modules');
805
- process.stderr.write(`\n[SETUP] import.meta.url: ${import.meta.url}\n`);
806
- process.stderr.write(`[SETUP] isNpx: ${isNpx}\n`);
805
+ logToFile(`\n[SETUP] import.meta.url: ${import.meta.url}\n`);
806
+ logToFile(`[SETUP] isNpx: ${isNpx}\n`);
807
807
  await trackEvent('npx_setup_execution_mode', { isNpx });
808
808
 
809
809
  // Fix Windows path handling for npx execution
@@ -862,7 +862,7 @@ export default async function setup() {
862
862
  try {
863
863
  appendFileSync(debugFile, `\n[SETUP] Creating config with package spec: ${packageSpec}\n`);
864
864
  } catch (e) { /* ignore */ }
865
- process.stderr.write(`\n[SETUP] Creating config with package spec: ${packageSpec}\n`);
865
+ logToFile(`\n[SETUP] Creating config with package spec: ${packageSpec}\n`);
866
866
  serverConfig = {
867
867
  "command": isWindows ? "npx.cmd" : "npx",
868
868
  "args": [
@@ -872,7 +872,7 @@ export default async function setup() {
872
872
  try {
873
873
  appendFileSync(debugFile, `[SETUP] serverConfig.args: ${JSON.stringify(serverConfig.args)}\n`);
874
874
  } catch (e) { /* ignore */ }
875
- process.stderr.write(`[SETUP] serverConfig.args: ${JSON.stringify(serverConfig.args)}\n`);
875
+ logToFile(`[SETUP] serverConfig.args: ${JSON.stringify(serverConfig.args)}\n`);
876
876
  await trackEvent('npx_setup_config_standard_npx', { packageSpec });
877
877
  } else {
878
878
  // For local installation, use absolute path to handle Windows properly
@@ -910,15 +910,15 @@ export default async function setup() {
910
910
  // Add or update the terminal server config with the proper name "desktop-commander"
911
911
  config.mcpServers["desktop-commander"] = serverConfig;
912
912
 
913
- process.stderr.write('\n[SETUP] Writing config to Claude:\n');
914
- process.stderr.write(`[SETUP] desktop-commander args: ${JSON.stringify(config.mcpServers["desktop-commander"].args)}\n`);
913
+ logToFile('\n[SETUP] Writing config to Claude:\n');
914
+ logToFile(`[SETUP] desktop-commander args: ${JSON.stringify(config.mcpServers["desktop-commander"].args)}\n`);
915
915
 
916
916
  // Write the updated config back
917
917
  writeFileSync(claudeConfigPath, JSON.stringify(config, null, 2), 'utf8');
918
918
 
919
919
  // Verify what was written
920
920
  const writtenConfig = JSON.parse(readFileSync(claudeConfigPath, 'utf8'));
921
- process.stderr.write(`[SETUP] Verified written args: ${JSON.stringify(writtenConfig.mcpServers["desktop-commander"].args)}\n\n`);
921
+ logToFile(`[SETUP] Verified written args: ${JSON.stringify(writtenConfig.mcpServers["desktop-commander"].args)}\n\n`);
922
922
 
923
923
  updateSetupStep(updateConfigStep, 'completed');
924
924
  await trackEvent('npx_setup_update_config');
package/dist/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const VERSION = "0.2.18-alpha.11";
1
+ export declare const VERSION = "0.2.18-alpha.12";
package/dist/version.js CHANGED
@@ -1 +1 @@
1
- export const VERSION = '0.2.18-alpha.11';
1
+ export const VERSION = '0.2.18-alpha.12';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wonderwhy-er/desktop-commander",
3
- "version": "0.2.18-alpha.11",
3
+ "version": "0.2.18-alpha.12",
4
4
  "description": "MCP server for terminal operations and file editing",
5
5
  "mcpName": "io.github.wonderwhy-er/desktop-commander",
6
6
  "license": "MIT",