syntaur 0.25.0 → 0.25.1

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "syntaur",
3
- "version": "0.25.0",
3
+ "version": "0.25.1",
4
4
  "description": "Project workflow CLI with dashboard, Claude Code plugin, and Codex plugin",
5
5
  "homepage": "https://github.com/prong-horn/syntaur#readme",
6
6
  "repository": {
@@ -360,12 +360,25 @@ function detectInstalledTerminals() {
360
360
  function buildTerminalDispatch(installedTerminals) {
361
361
  const branches = [];
362
362
  if (installedTerminals.has('terminal-app')) {
363
+ // Terminal.app cold-start quirk: launching it auto-opens a blank window,
364
+ // and `do script` opens ANOTHER — two windows, one blank. Capture the
365
+ // running state BEFORE the `tell` block (addressing Terminal would launch
366
+ // it), then on a cold start run the command in the blank launch window
367
+ // instead of opening a second one. Warm starts still get a fresh window.
363
368
  branches.push({
364
369
  id: 'terminal-app',
365
370
  block: [
371
+ '\t\t\tset wasRunning to application "Terminal" is running',
366
372
  '\t\t\ttell application "Terminal"',
367
373
  '\t\t\t\tactivate',
368
- '\t\t\t\tdo script shellCmd',
374
+ '\t\t\t\tif wasRunning then',
375
+ '\t\t\t\t\tdo script shellCmd',
376
+ '\t\t\t\telse',
377
+ '\t\t\t\t\trepeat until (count of windows) > 0',
378
+ '\t\t\t\t\t\tdelay 0.1',
379
+ '\t\t\t\t\tend repeat',
380
+ '\t\t\t\t\tdo script shellCmd in window 1',
381
+ '\t\t\t\tend if',
369
382
  '\t\t\tend tell',
370
383
  ],
371
384
  });