bug: No such file or directory, open 'C:\workspace\angular-demo\pdf\**\*.md'
cheikhnadiouf opened this issue · 3 comments
This command md-to-pdf ./pdf/**/*.md
can't find the multiple path folders
I am using version 5.2.4
generating PDF from ./pdf/**/*.md → ENOENT: no such file or directory, open 'C:\workspace\angular-demo\pdf\**\*.md' ListrError: Something went wrong at C:\workspace\angular-demo\node_modules\listr\index.js:102:18 at async main (C:\workspace\angular-demo\node_modules\md-to-pdf\dist\cli.js:120:5) { errors: [ [Error: ENOENT: no such file or directory, open 'C:\workspace\angular-demo\pdf\**\*.md'] { errno: -4058, code: 'ENOENT', syscall: 'open', path: 'C:\\workspace\\angular-demo\\pdf\\**\\*.md' } ], context: [Object: null prototype] {} }
Duplicate of #136 I guess. Wildcard expansion is not supported by cmd.exe... use powershell or WSL (windows subsystem for linux), or figure out how cmd.exe can expand a list of files into the command 😅
Guys, guys, guys
Closing a ticket without even waiting for a feedback of a user is the best way of discrediting all open source solutions.
Even on powershell , in windows it is not working. You should check it yourself.
Not sure what you're going on about, the ticket seemed non-actionable to me so I closed it, but I'm always happy to re-open when I receive actionable feedback. It's not like I locked it, you can still comment.
You should check it yourself.
Can't do that as I don't have a Windows machine.
Maybe this SO article can help you: https://stackoverflow.com/a/43900040/2897426. According to that something like the following should work:
md-to-pdf (Get-Item .\pdf\*.md).FullName
Not sure about recursing folders, i.e. the **
in your case but a quick google search shows that Get-ChildItem has a recursive option.