gpt4 book ai didi

lisp - 如何调用Racket中的其他程序?

转载 作者:太空宇宙 更新时间:2023-11-03 18:51:59 25 4
gpt4 key购买 nike

我可以使用以下命令在 Windows CMD 中成功运行 pandoc:

pandoc test.md -o test.html

然后我想在 Racket 中做同样的事情,我试过了:

(subprocess #f #f #f "pandoc" "test.md -o test.html")

和:

(shell-execute "pandoc" "" "test.md -o test.html" (current-directory) 'sw_showdefault)

但他们都没有给我预期的 .html 文件。

正确的做法是什么?谢谢。

最佳答案

我同意 Joshua 的观点,即很难知道如何回答您最初提出的问题。也许你会编辑它。同时,按照最初的要求回答:

我认为在 Racket 中相当于“在命令提示符下键入它”是 system , 或更好 system* .

(system "pandoc test.md -o test.html")

关于lisp - 如何调用Racket中的其他程序?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18893291/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com