作者热门文章
- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我希望在启动 emacs 时启动多个进程,例如一个 eshell 中的网络服务器和另一个 shell 中的 weblogic 实例,但每当我尝试向 eshell 发送命令时,Emacs 就会挂起。我也尝试过使用“交互式”命令,但 Emacs 仍然挂起。
最佳答案
(require 'cl)
(defun eshell-run (programs)
(loop for p in programs for i from 1 do
(with-current-buffer (eshell i)
(insert p)
(eshell-send-input))))
(eshell-run '("program1" "program2"))
如果将以上几行添加到 init 文件中,最后一行列出的程序将在您启动 Emacs 时自动执行。
关于emacs - 在 Emacs 中向多个 Shell 发送命令,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4292377/
我是一名优秀的程序员,十分优秀!