PDA

¸ðµç ±â´ÉÀ» Æ÷ÇÔÇØ¼­ º¸±â : AppleScript: ¹èÅ͸® ÇöȲ


albireo
2005/07/05, 03:49 PM
±»ÀÌ Terminal À̳ª System Profiler ¸¦ ¿­¾îº¼ ÇÊ¿ä¾øÀÌ, ÆÄ¿öºÏÀÇ ½Åǰ´ëºñ Çö ¹èÅ͸® ¿ë·®°ú ¿ÏÃæ/¿Ï¹æ Ƚ¼ö¸¦ Ç¥½ÃÇØ ÁÖ´Â µÎ ÁÙÂ¥¸® ½ºÅ©¸³Æ®ÀÔ´Ï´Ù ;-)

-- This two-line script shows current battery status of PowerBook.
-- Written by Hongsun Yoon, M.D., Albireo Project, July 2005

set battery_info to (do shell script "ioreg -p IODeviceTree -n battery -w 0| grep IOBatteryInfo")
display dialog battery_info buttons {"OK"} default button 1 giving up after 30