有几种情况我有一些输出,例如
thing1
thing2
thing3
Run Code Online (Sandbox Code Playgroud)
但一直想做类似的事情:
*command* thing1
*command* thing2
*command* thing3
Run Code Online (Sandbox Code Playgroud)
一个例子是:假设我想杀死所有屏幕会话。有什么办法可以让我得到一个命令来使用类似的东西:
screen -ls
Run Code Online (Sandbox Code Playgroud)
这可能会导致
88.mine (detached)
22.mine (detached)
Run Code Online (Sandbox Code Playgroud)
我可以做一些会导致所有可能的命令的事情,例如:
screen -S 88.mine test -X
screen -S 88.mine test -X
Run Code Online (Sandbox Code Playgroud)
一举?