Mac OS X: 实用脚本程序(bash scripts)系列-3

History:

2009-07-03: Added NetBoot command.

解决Finder里面隐藏系统文件的问题:

sudo /Developer/Tools/SetFile -a V /bin
sudo /Developer/Tools/SetFile -a V /cores
sudo /Developer/Tools/SetFile -a V /dev
sudo /Developer/Tools/SetFile -P -a V /etc
sudo /Developer/Tools/SetFile -a V /home
sudo /Developer/Tools/SetFile -a V /mach_kernel
sudo /Developer/Tools/SetFile -a V /mach_kernel.ctfsys

sudo /Developer/Tools/SetFile -a V /net
sudo /Developer/Tools/SetFile -a V /private
sudo /Developer/Tools/SetFile -a V /sbin
sudo /Developer/Tools/SetFile -P -a V /tmp
sudo /Developer/Tools/SetFile -a V /usr
sudo /Developer/Tools/SetFile -a V /Volumes
sudo /Developer/Tools/SetFile -P -a V /var

sudo rm -f /Library/Caches/com.apple.LaunchServices*.csstore

sudo reboot


设置从NetBoot服务启动:

/usr/sbin/bless --netboot --server <url or ip of server> --nextonly

你可能感兴趣的:(Mac OS X)