杀死"loginwindow" Mac OS X中使用命令行进行处理 [英] Kill "loginwindow" process using command line in Mac OS X

查看:525
本文介绍了杀死"loginwindow" Mac OS X中使用命令行进行处理的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

到目前为止,我已经编写了以下unix命令:

So far, I have written the following unix command:

ps -Ajc | grep loginwindow | cut -c 16-20 | sed 's/ //g'

这将抓取"loginwindow"进程,并使用cut和sed对其进行过滤以返回"loginwindow"进程的编号.

This grabs the "loginwindow" process, filters it using cut and sed to return the number of the "loginwindow" process.

我想知道如何使用检索到的数字进行处理.

I'd like to know how to use the number retrieved to the process.

谢谢.

推荐答案

这似乎很漫长.为什么不只使用killall loginwindow?

This seems like the long way around. Why not just use killall loginwindow?

这篇关于杀死"loginwindow" Mac OS X中使用命令行进行处理的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆