Skip to content

Accept multiple markdown files as arguments - #78

Merged
masawada merged 7 commits into
mainfrom
multiple-files
Sep 4, 2026
Merged

masawada merged 7 commits into
mainfrom
multiple-files

Conversation

@masawada

@masawada masawada commented Sep 4, 2026

Copy link
Copy Markdown
Owner

Why

`mdp` only took a single markdown file, so previewing related documents together meant running it once per file. Passing several files at once opens each in its own tab and lets `--watch` cover all of them.

What

  • Accept every positional argument as a file path; check all files, dedupe by absolute path, and reject output path collisions before converting so a bad argument generates and opens nothing.
  • Convert all files first, then open each output in the browser; `--watch` now watches every file with one fsnotify instance and regenerates only the changed one.
  • Add unit tests for args, cli, and watcher, plus an e2e case that passes two files and checks both outputs and browser invocations.

@masawada
masawada merged commit 286b91a into main Sep 4, 2026
5 checks passed
@masawada
masawada deleted the multiple-files branch September 4, 2026 07:26
@github-actions github-actions Bot mentioned this pull request Sep 4, 2026
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.

1 participant