Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions agterm/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -50,18 +50,28 @@
<string>Command-line tools you run inside agterm (for example, ffmpeg capturing video) request camera access through agterm.</string>
<key>NSContactsUsageDescription</key>
<string>Command-line tools you run inside agterm request access to your contacts through agterm.</string>
<key>NSDesktopFolderUsageDescription</key>
<string>Command-line tools you run inside agterm request access to your Desktop folder through agterm.</string>
<key>NSDocumentsFolderUsageDescription</key>
<string>Command-line tools you run inside agterm request access to your Documents folder through agterm.</string>
<key>NSDownloadsFolderUsageDescription</key>
<string>Command-line tools you run inside agterm request access to your Downloads folder through agterm.</string>
<key>NSLocalNetworkUsageDescription</key>
<string>Command-line tools you run inside agterm (for example, connecting to a .local host) request local network access through agterm.</string>
<key>NSLocationUsageDescription</key>
<string>Command-line tools you run inside agterm request your location through agterm.</string>
<key>NSMicrophoneUsageDescription</key>
<string>Command-line tools you run inside agterm (for example, voice dictation in Claude Code) request microphone access through agterm.</string>
<key>NSNetworkVolumesUsageDescription</key>
<string>Command-line tools you run inside agterm request access to files on network volumes through agterm.</string>
<key>NSPhotoLibraryUsageDescription</key>
<string>Command-line tools you run inside agterm (for example, osxphotos) request access to your photo library through agterm.</string>
<key>NSRemindersFullAccessUsageDescription</key>
<string>Command-line tools you run inside agterm request access to your reminders through agterm.</string>
<key>NSRemindersUsageDescription</key>
<string>Command-line tools you run inside agterm request access to your reminders through agterm.</string>
<key>NSRemovableVolumesUsageDescription</key>
<string>Command-line tools you run inside agterm request access to files on removable volumes through agterm.</string>
<key>NSSpeechRecognitionUsageDescription</key>
<string>Command-line tools you run inside agterm request speech recognition through agterm.</string>
<key>NSSystemAdministrationUsageDescription</key>
Expand Down
18 changes: 9 additions & 9 deletions agtermCore/Sources/agtermCore/AgentHooksInstall.swift
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@ public enum AgentHooksInstall {

/// The bundled Pi extension's path relative to the agent-status package, and its destination filename.
public static let piExtensionRelativePath = "pi/agterm-status.ts"
public static let piExtensionName = "agterm-status.ts"
static let piExtensionName = "agterm-status.ts"

/// Ownership sentinel in the bundled Pi extension: a reinstall refuses to overwrite an unmarked same-named
/// extension, preserving a user-authored integration.
public static let piExtensionMarker = "// agterm-pi-status-extension"

/// The bundled OpenCode plugin's path relative to the agent-status package, and its destination filename.
public static let opencodePluginRelativePath = "opencode/agterm-status.js"
public static let opencodePluginName = "agterm-status.js"
static let opencodePluginName = "agterm-status.js"

/// Ownership sentinel in the bundled OpenCode plugin, same policy as `piExtensionMarker`. Named `*Plugin*`
/// (not `*Extension*`) because OpenCode's host term is plugin — a deliberate divergence from `piExtension*`.
Expand All @@ -36,8 +36,8 @@ public enum AgentHooksInstall {

/// Marker lines bracketing the agterm-managed block in a shell rc file; the opening marker is also the
/// idempotency probe (present → already installed).
public static let rcMarkerBegin = "# >>> agterm agent-status >>>"
public static let rcMarkerEnd = "# <<< agterm agent-status <<<"
static let rcMarkerBegin = "# >>> agterm agent-status >>>"
static let rcMarkerEnd = "# <<< agterm agent-status <<<"

/// The Claude Code hook events the merge installs, paired with the state (plus flags) each maps to.
/// `UserPromptSubmit` and `PostToolUse` both set `active` — the latter after every tool run, so the status
Expand All @@ -64,7 +64,7 @@ public enum AgentHooksInstall {
]

/// The destination directory for Pi's auto-discovered global extensions.
public static func piExtensionDirectory(home: String) -> String {
static func piExtensionDirectory(home: String) -> String {
home + "/.pi/agent/extensions"
}

Expand All @@ -81,7 +81,7 @@ public enum AgentHooksInstall {
}

/// The destination directory for OpenCode's auto-discovered global plugins.
public static func opencodePluginDirectory(home: String) -> String {
static func opencodePluginDirectory(home: String) -> String {
home + "/.config/opencode/plugins"
}

Expand Down Expand Up @@ -286,11 +286,11 @@ public enum AgentHooksInstall {

/// the absolute wrapper-script path the installed hooks invoke (`<scriptDir>/agterm-agent-status.sh`); the
/// caller's hook entry appends the state.
public static func wrapperPath(scriptDir: String) -> String {
static func wrapperPath(scriptDir: String) -> String {
scriptDir + "/" + wrapperName
}

public static func codexWrapperPath(scriptDir: String) -> String {
static func codexWrapperPath(scriptDir: String) -> String {
scriptDir + "/" + codexWrapperName
}

Expand All @@ -299,7 +299,7 @@ public enum AgentHooksInstall {
/// merge declines, and nothing checks the two against each other.
/// The wrapper's absolute path is baked into each command — shell-quoted (so a path with spaces stays one
/// token) inside a TOML basic string — so the hook fires without the CLI on PATH.
public static func codexHooksBlock(scriptDir: String) -> String {
static func codexHooksBlock(scriptDir: String) -> String {
let wrapper = shellQuote(codexWrapperPath(scriptDir: scriptDir))
return codexHooks.map { hook in
"""
Expand Down
2 changes: 1 addition & 1 deletion agtermCore/Sources/agtermCore/ConfigPaths.swift
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public enum ConfigPaths {
# Examples:
#
# command "Open in Zed" cmd+shift+e open -a Zed "$AGT_SESSION_PWD"
# command "Lazygit" ctrl+a>g agtermctl session overlay open 'zsh -lc lazygit' --socket "$AGT_SOCKET"
# command "Lazygit" ctrl+a>g agtermctl session overlay open 'zsh -lc lazygit' --target "$AGT_SESSION_ID" --socket "$AGT_SOCKET"
# command "Deploy" ./deploy.sh
#
# global-hotkey <chord>
Expand Down
2 changes: 1 addition & 1 deletion agtermCore/Tests/agtermCoreTests/ConfigPathsTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ struct ConfigPathsTests {
#expect(starter.contains("command \"<name>\" [chord] <shell...>"))
#expect(starter.contains("single chord OR a leader like `ctrl+a>g`"))
#expect(starter.contains("command \"Open in Zed\" cmd+shift+e open -a Zed \"$AGT_SESSION_PWD\""))
#expect(starter.contains("command \"Lazygit\" ctrl+a>g agtermctl session overlay open 'zsh -lc lazygit' --socket \"$AGT_SOCKET\""))
#expect(starter.contains("command \"Lazygit\" ctrl+a>g agtermctl session overlay open 'zsh -lc lazygit' --target \"$AGT_SESSION_ID\" --socket \"$AGT_SOCKET\""))
#expect(starter.contains("command \"Deploy\" ./deploy.sh"))
#expect(starter.contains("ctrl+shift+p"))
#expect(!starter.contains("super"))
Expand Down
19 changes: 0 additions & 19 deletions docs/backlog/codex-wrapper-path-is-public-with-no-consumer.md

This file was deleted.

25 changes: 0 additions & 25 deletions docs/backlog/no-folder-usage-strings-in-info-plist.md

This file was deleted.

29 changes: 0 additions & 29 deletions docs/backlog/seeded-lazygit-example-omits-target.md

This file was deleted.

Loading