@yemi33/minions 0.1.1559 → 0.1.1560

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/CHANGELOG.md CHANGED
@@ -1,10 +1,13 @@
1
1
  # Changelog
2
2
 
3
- ## 0.1.1559 (2026-04-27)
3
+ ## 0.1.1560 (2026-04-27)
4
4
 
5
5
  ### Features
6
6
  - removeProject also archives plans + PRDs targeting the project
7
7
 
8
+ ### Fixes
9
+ - handle project browse cancel
10
+
8
11
  ## 0.1.1558 (2026-04-27)
9
12
 
10
13
  ### Fixes
package/dashboard.js CHANGED
@@ -3707,11 +3707,12 @@ What would you like to discuss or change? When you're happy, say "approve" and I
3707
3707
 
3708
3708
  async function handleProjectsBrowse(req, res) {
3709
3709
  try {
3710
- const { execSync } = require('child_process');
3710
+ const { execSync, execFileSync } = require('child_process');
3711
3711
  let selectedPath = '';
3712
3712
  if (process.platform === 'win32') {
3713
- // PowerShell STA with topmost window as owner forces folder dialog to foreground
3714
- // Write PS script to temp file to avoid shell quoting issues
3713
+ // Launch PowerShell directly (not through cmd.exe) and hide its console so
3714
+ // only the folder picker is visible. Closing the picker should cancel cleanly
3715
+ // instead of surfacing a raw shell "Command failed" error.
3715
3716
  const psScript = [
3716
3717
  'Add-Type -AssemblyName System.Windows.Forms',
3717
3718
  '$f = New-Object System.Windows.Forms.FolderBrowserDialog',
@@ -3730,10 +3731,43 @@ What would you like to discuss or change? When you're happy, say "approve" and I
3730
3731
  fs.mkdirSync(path.dirname(psPath), { recursive: true });
3731
3732
  fs.writeFileSync(psPath, psScript);
3732
3733
  try {
3733
- selectedPath = execSync(`powershell -STA -NoProfile -ExecutionPolicy Bypass -File "${psPath}"`, { encoding: 'utf8', timeout: 120000 }).trim();
3734
+ selectedPath = execFileSync('powershell.exe', [
3735
+ '-STA',
3736
+ '-NoProfile',
3737
+ '-ExecutionPolicy', 'Bypass',
3738
+ '-File', psPath,
3739
+ ], {
3740
+ encoding: 'utf8',
3741
+ timeout: 120000,
3742
+ windowsHide: true,
3743
+ stdio: ['ignore', 'pipe', 'pipe'],
3744
+ }).trim();
3745
+ } catch (e) {
3746
+ const stdout = String(e.stdout || '').trim();
3747
+ const stderr = String(e.stderr || '').trim();
3748
+ const signal = String(e.signal || '').toUpperCase();
3749
+ const status = Number.isInteger(e.status) ? e.status : null;
3750
+ const interrupted = signal === 'SIGINT' || signal === 'SIGBREAK' || status === 0xC000013A;
3751
+ if (interrupted && !stdout && !stderr) return jsonReply(res, 200, { cancelled: true });
3752
+ throw e;
3734
3753
  } finally { try { fs.unlinkSync(psPath); } catch { /* cleanup */ } }
3735
3754
  } else if (process.platform === 'darwin') {
3736
- selectedPath = execSync(`osascript -e 'POSIX path of (choose folder with prompt "Select project folder")'`, { encoding: 'utf8', timeout: 120000 }).trim();
3755
+ try {
3756
+ selectedPath = execFileSync('osascript', [
3757
+ '-e',
3758
+ 'POSIX path of (choose folder with prompt "Select project folder")',
3759
+ ], {
3760
+ encoding: 'utf8',
3761
+ timeout: 120000,
3762
+ stdio: ['ignore', 'pipe', 'pipe'],
3763
+ }).trim();
3764
+ } catch (e) {
3765
+ const stderr = String(e.stderr || '').trim();
3766
+ const message = String(e.message || '').trim();
3767
+ const cancelled = stderr.includes('User canceled') || message.includes('User canceled') || message.includes('(-128)') || stderr.includes('(-128)');
3768
+ if (cancelled) return jsonReply(res, 200, { cancelled: true });
3769
+ throw e;
3770
+ }
3737
3771
  } else {
3738
3772
  selectedPath = execSync(`zenity --file-selection --directory --title="Select project folder" 2>/dev/null`, { encoding: 'utf8', timeout: 120000 }).trim();
3739
3773
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yemi33/minions",
3
- "version": "0.1.1559",
3
+ "version": "0.1.1560",
4
4
  "description": "Multi-agent AI dev team that runs from ~/.minions/ — five autonomous agents share a single engine, dashboard, and knowledge base",
5
5
  "bin": {
6
6
  "minions": "bin/minions.js"