john c. j.
john c. j.

Reputation: 1175

How to convert multiple markdown files at once

I have a folder with several markdown files and I need to convert them to HTML at once.

This works fine:

multimarkdown -b file1.txt file2.txt file3.txt

But this doesn't:

multimarkdown -b *.txt

I get the error in the cmd window:

*.txt: Invalid argument

I also tried multimarkdown -b "*.txt" and multimarkdown "*.txt" -b, but still doesn't work.

Maybe I miss something? (I use MultiMarkdown 5.4.0)

Upvotes: 0

Views: 269

Answers (1)

mb21
mb21

Reputation: 39229

The star syntax is actually part of bash which is a unix shell (Mac/Linux), so you I think you won't be able to use it with cmd on Windows.

Use PowerShell instead, or write your own loop, like:

for /r %i in (*.txt) do multimarkdown -b %i

Upvotes: 1

Related Questions