Closed manuth closed 2 years ago
I'm sure this works, but it is overkill for quote wrapping. I'm trying to find the NodeJS code that deals with it to copy their implementation.
Awesome! thanks for taking care about it 😄
I can't figure out how nodeJS sanitizes it but I confirmed that it works. This looks good.
Could you bump the last number of the version? It will be good to merge after that.
Couldn't find it either - I couldn't find the process_wrap
of their code base.
Alright, will do!
@manuth Thank you!
Currently, commands are being executed using
child_process.exec
which doesn't allow passing parameters. Therefore, commands are generated dynamically as seen here: https://github.com/telesoho/vscode-markdown-paste-image/blob/3ef1162ecfca16bf04944bc0028fbe0b42ef0ac2/src/paster.ts#L55This causes commands with arguments containing whitespaces to break.
As opposed to
child_process.exec
,child_process.spawn
allows passing arguments (as a string array). This PR replaces the use ofchild_process.exec
withchild_process.spawn
fixing all issues related to whitespaces.Marging this PR will fix #60