Skip to content

Macro runner with iTerm primitives #26

Description

@sebastientaggart

Context

Press button → sequence of OS actions (open tab, run command, switch tab, type text).

Scope

  • New plugin deckhand.plugins.macros. Reads macros from config.toml under [macros.<id>] with a steps list.
  • Step primitives: iterm.new_tab {cwd, cmd}, iterm.send_text {text}, iterm.focus_tab {index}, shell.run {cmd, cwd}, delay.ms {ms}.
  • New action macro.run with payload {macro_id}.
  • Pick one of: iTerm Python API or AppleScript. Commit to it. Document why.
  • No conditionals, variables, or error branches in the DSL. If logic is needed, write a Python plugin function instead.

Demo macro

  • Ship one generic demo in examples/macros.example.toml that doesn't assume user filesystem layout — e.g., "open a tab in the current shell's $PWD and run pwd && ls."
  • Do not check in personal macros (e.g., "Start working on Code Cannon"). Those live in the user's own config.toml, not the repo.

Acceptance

  • macro.run with {"macro_id": "demo"} opens an iTerm tab and runs the demo commands.
  • A personal Code Cannon macro can be defined out-of-tree and works.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions