【发布时间】:2012-01-18 12:07:23
【问题描述】:
我认为这会起作用:
(defun my-node ()
(interactive)
(pop-to-buffer (make-comint "my-node" "node")))
但是当我执行M-x my-node 并在comint 缓冲区中输入1+1 时,它不会显示任何输出。
这是在 Windows 7 上的 Emacs 24.0.50.1 中,NodeJS 无需任何特殊配置即可安装。
像M-x compile RET node hello-world.js RET 那样以非交互方式调用 node.js 可以正常工作。在cmd 中以交互方式运行node 工作正常。
这可能与此有关:当我运行 M-x shell 并在 shell 缓冲区中输入 node 然后输入 1+1 时,它不会显示结果。我一定遗漏了一些非常基本的东西。
更新:
可能相关:emacs/Python: running python-shell in line buffered vs. block buffered mode - Stack Overflow
【问题讨论】:
标签: javascript node.js emacs