我正在尝试watch "ps aux | grep myShittyProcess"在 tmux 会话中运行它 。这个过程myShittyProcess也是在 tmux 会话中启动的。在ps aux没有钟表命令工作。但是一旦我将它放入监视中,它就无法执行。如何让这个工作?
watch "ps aux | grep myShittyProcess"
myShittyProcess
ps aux
- 编辑 -
发现将 tmux 调整为全屏使其工作。与ps输出包装有关,grep无法在包装的上下文中找到。
ps
grep
linux grep ps tmux
grep ×1
linux ×1
ps ×1
tmux ×1