Skip to content

feat(linux): --launch opens the pages xdg-open passes; desktop entry handles web content - #63

Merged
NagyVikt merged 2 commits into
mainfrom
fix/open-url-arg
Oct 9, 2026
Merged

NagyVikt merged 2 commits into
mainfrom
fix/open-url-arg

Conversation

@NagyVikt

@NagyVikt NagyVikt commented Oct 9, 2026

Copy link
Copy Markdown
Collaborator

Why

Double-clicking an .html file, or choosing ego lite as the HTML handler, opened nothing. The desktop entry ran --spaces without %U, so the file never reached the browser, and the entry declared no MimeType.

What

  • --launch [url|file ...] opens each page in a plain tab of the shared window and raises it. With no arguments it shows the Spaces overview, as before.
  • A relative or absolute path becomes a file:// URL (launchTargets in src/desktop.mjs).
  • Tabs are opened with CDP Target.createTarget, not ego.createTab. ego.createTab files the tab into the agents' selected task space and silently does nothing while a person has taken that space over, which is how the first attempt failed.
  • --open now shares the same openPages() code.
  • Desktop entry: Exec=… --launch %U, plus MimeType=text/html;application/xhtml+xml;x-scheme-handler/http;x-scheme-handler/https;.

Checks

  • test/desktop-entry.test.mjs: 3/3 pass, including the new tests for Exec/MimeType and launchTargets.
  • installer.test.mjs and doctor-cli.test.mjs fail the same way on origin/main on this machine, so this PR adds no new failures.
  • Manual: ego-browser.mjs --launch <report.html> opened the report tab. Confirmed with the DevTools target list while a person had taken control of the task space.

🤖 Generated with Claude Code

NagyVikt and others added 2 commits October 9, 2026 11:16
…handles web content

Clicking an .html file or a link could not open in ego lite: the desktop
entry ran --spaces with no %U, so the page never reached the browser, and
the desktop had no MimeType to offer it for. --launch [url|file ...] opens
each page in a plain tab of the shared window (not ego.createTab, which
files it into the agents' selected task space and does nothing while a
person controls that space) and raises it; with no pages it still shows the
Spaces overview. --open now shares that code path.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… browser

Review of #63: anything xdg-open hands over opens in the browser the agents
drive with their logins, so javascript:, chrome:// and view-source: now read
as paths (and so do Windows drive paths and single-dash arguments).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@NagyVikt
NagyVikt merged commit 547266c into main Oct 9, 2026
4 of 6 checks passed
@NagyVikt
NagyVikt deleted the fix/open-url-arg branch October 9, 2026 09:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant