Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot set 'mermaid_cmd' to multiple words #89

Closed
slanzmich opened this issue Jul 26, 2022 · 9 comments · Fixed by #138
Closed

Cannot set 'mermaid_cmd' to multiple words #89

slanzmich opened this issue Jul 26, 2022 · 9 comments · Fixed by #138

Comments

@slanzmich
Copy link
Contributor

Currently, mermaid_cmd cannot be set to a command containing arguments / multiple words, e.g. npx mmdc. Neither

mermaid_cmd = "npx mmdc"

nor

mermaid_cmd = ["npx", "mmdc"]

work, because the command is always passed as first item of a list to os.Popen.

What do you think about always supporting the second form, and support the first form (by calling shlex.split on string input) if mermaid_cmd_shell is set?

@mgaitan
Copy link
Owner

mgaitan commented Aug 28, 2022

hey @slanzmich , that sounds ok. could you send a PR?

@Gabrielcarvfer
Copy link

@mgaitan #79 does that. :)

@slanzmich
Copy link
Contributor Author

Right, #79 would solve my issue. On the other hand, always splitting the string will break things for people specifying a path containing spaces. To support both, a list of strings should also be accepted. I'll send a PR.

@slanzmich
Copy link
Contributor Author

I opened #91 with an alternative implementation.

@tuncbkose
Copy link
Contributor

I could also use this

@mgaitan
Copy link
Owner

mgaitan commented May 30, 2024

could somebody update the pr to resolve the conflicts?

@tuncbkose
Copy link
Contributor

tuncbkose commented May 31, 2024

Hmm, the conflicts seem easy to fix but I'm not sure how to do that without access to @slanzmich's repo. Would it work if I forked their repo and made a separate pr? You also may have maintainer access to that branch.

@mgaitan
Copy link
Owner

mgaitan commented May 31, 2024

@tuncbkose sure!

@tuncbkose
Copy link
Contributor

Thank you! Any idea when there may be a new version release?

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 a pull request may close this issue.

4 participants