Skip to content

Feature Request: --stdin support #165

@knwoop

Description

@knwoop

What

Support reading Markdown from stdin.

some-command | mo --stdin
some-command | mo --stdin --name "result.md" --target review

Why

I often pipe Markdown output (e.g. plans, diffs formatted as Markdown) from CLI tools to preview in a browser. Currently I write to a temp file first:

some-command > /tmp/out.md && mo /tmp/out.md

Since mo already handles in-memory content via drag-and-drop (without live-reload), --stdin could work the same way — read until EOF, send to the running server, done.

Proposed behavior

  • Read stdin until EOF, add content to the session
  • --name to set the sidebar display name (default: stdin-<timestamp>)
  • Same name replaces existing content
  • No live-reload (same as drag-and-drop)
  • Non-blocking, consistent with existing background-server behavior
  • Works with --target for grouping

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions