Skip to content

CLI: add an --action option to trigger button presses (press / long-press) #619

Description

@miguelangellv

Describe the feature idea

Add a CLI option to trigger a button action (for example: press, long-press) the same way the CLI can already change a button's state. This would allow automating button actions from scripts and CI, reusing the plugins and actions already configured in StreamController.

Proposed CLI examples:

  • Change state (already supported):
    streamcontroller --change-state CL123456789 Main 0,0 1

  • New action CLI (examples):
    streamcontroller --action press CL123456789 Main 0,0
    streamcontroller --action long-press CL123456789 Main 0,0

Behavior expectations:

  • --action should accept an action type (e.g. press, long-press) and the same identifier parameters used by --change-state (controller ID, page, button coordinates).
  • It should trigger the same plugin hooks and actions that a manual button press triggers in the UI, including any configured macros, plugins, or downstream integrations.
  • It should return an exit code indicating success or failure and optionally print a brief result message to stdout/stderr for scripting.

Additional context

Having a CLI to execute button actions will make it easy to drive StreamController from external scripts, automation tools, and CI pipelines, and will help integrate existing button-based workflows without duplicating logic. This feature complements the existing --change-state command by providing a way to simulate real user interactions (press and long-press) via automation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    Status
    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions