Skip to content

feat: add Otty terminal support - #276

Open
pintaste wants to merge 1 commit into
Ji4n1ng:masterfrom
pintaste:feat/otty-support
Open

feat: add Otty terminal support#276
pintaste wants to merge 1 commit into
Ji4n1ng:masterfrom
pintaste:feat/otty-support

Conversation

@pintaste

Copy link
Copy Markdown

Summary

Add first-class support for Otty terminal.

This follows the same pattern as Ghostty / cmux / Kaku:

  1. Register Otty in SupportedApps (bundle id io.appmakes.otty)
  2. Treat it as a terminal so Lite / full app / Finder extension can pick it
  3. Ship a menu icon (repo already had a partial otty imageset — renamed to Otty to match the app name, icon refreshed from Otty.app)
  4. Document it in the English/Chinese READMEs and Lite defaults table

How opening works

Otty registers public.folder as a document type, so the existing safe path works:

/usr/bin/open -a Otty <folder-path>

No custom shell string, no AppleScript path interpolation — same injection-safe discrete-argument approach used after the recent security fix.

Lite: set Otty as default

defaults write wang.jianing.app.OpenInTerminal-Lite LiteDefaultTerminal Otty

Test plan

  • xcodebuild OpenInTerminalCore — BUILD SUCCEEDED
  • xcodebuild OpenInTerminal — BUILD SUCCEEDED
  • xcodebuild OpenInTerminal-Lite — BUILD SUCCEEDED
  • xcodebuild OpenInEditor-Lite — BUILD SUCCEEDED
  • Framework smoke checks: SupportedApps.from("Otty"), type, bundle id, getOpenArguments["-a", "Otty"]
  • Runtime: open -a Otty with normal path, path with spaces/quotes, and a shell-injection-looking path (no injection file created)
  • End-to-end: Lite with LiteDefaultTerminal=Otty opens /tmp/... via open -a Otty ... (exit 0)

Manual check for reviewers

  1. Install Otty from https://otty.sh/ to /Applications/Otty.app
  2. Build OpenInTerminal-Lite, set default to Otty (picker or defaults write above)
  3. Open a Finder folder → click toolbar icon → Otty opens at that folder
  4. In full OpenInTerminal prefs, set default terminal to Otty and use context menu / shortcut

Notes

  • I maintain a tiny dedicated toolbar app (OpenInOtty) for Otty-only users; this PR is the proper upstream integration so multi-terminal users get Otty without a separate app.
  • Happy to adjust naming/icon if you prefer keeping the imageset as lowercase otty.

Register Otty (https://otty.sh/) as a first-class terminal, same way
as Ghostty/cmux: SupportedApps entry + icon + docs.

Otty declares public.folder support, so the generic open -a path works
safely with discrete Process arguments (no shell interpolation).

Also rename the existing otty icon imageset to Otty so NSImage(named:)
matches the app name, refresh the icon from Otty.app, and fix the
Lite-zh Ghostty defaults example casing.
@murasame612

Copy link
Copy Markdown

Independent verification on macOS with Otty 1.2.3:

  • Confirmed CFBundleIdentifier = io.appmakes.otty and that Otty declares public.folder support, so the existing discrete-argument /usr/bin/open -a Otty flow is appropriate.
  • Built all four workspace schemes successfully with code signing disabled: OpenInTerminal, OpenInTerminalCore, OpenInTerminal-Lite, and OpenInEditor-Lite.
  • Framework smoke check returned Otty, terminal, io.appmakes.otty, and ["-a", "Otty"] for getOpenArguments.
  • git diff --check is clean.

This looks ready from the Otty integration side. The only PR-template follow-up I noticed is linking the existing request with Closes #266.

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.

2 participants