分享有用的Linux command

2014-11-23 23:26:47 · 作者: · 浏览: 12

去掉多余的回车符
sed 's/^M//' test.sh > back.sh, 注意^M是敲ctrl_v ctrl-m得到的


查找权限位为S的文件
find . -type f \( -perm -04000 -o -perm -02000 \) -exec ls -lg {} \;


把弹出的光盘收回来
eject –t


查找或删除正在使用某文件的进程
fuser filename
fuser -k filename