I'm trying to write a script that will display some system infomation on IRC I have an example of what I'm wanting it too look like which follows:
Mac mini - CPU: 1 x Intel Core Solo - Speed: 1.5 GHz - RAM Usage: 384 MB / 512 MB [||||||||||] - Disk Space: 353.54 GB with 192.02 GB Free - Running: Mac OS X 10.5 (9A559) - Processes: 61 - Uptime: 12:20 up 14:13, 1 user, load averages: 0.60 0.19 0.07 - What the goal is!
So far I have
set theInfo to do shell script "/usr/sbin/system_profiler -detailLevel mini | egrep '(System Version|Processor Name|Processor Speed|Memory): ' | cut -d: -f2-"
set AppleScript's text item delimiters to return
set theList to text items of theInfo
set AppleScript's text item delimiters to ""-- get results
item 1 of theList -- Cpu Name
item 2 of theList -- cpu Speed
item 3 of theList -- Ram
item 4 of theList -- system version
3rd word of item 4 of theList -- build version
display dialog "You are running" & item 4 of theList & "You have a" & item 1 of theList & " Which is running at:" & item 2 of theList & " You have:" & item 3 of theList & " Of Ram" -- show how much ram we have and what version of mac os x we are running and speed of CPU
As you see this will show a dialog of which version of OSX, name of CPU, CPU speed and how much Ram, which is fine while I finish this.
The only thing I cannot work out is how to get How much drive space there is and how much is free also how many processes including
uptime, also how much ram is being used.
Thanks for any help you can provide