Forums
New posts
Articles
Product Reviews
Policies
FAQ
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Menu
Log in
Register
Install the app
Install
Forums
Apple Computing Products:
macOS - Apps and Programs
Geektool scripts
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="applemaniac" data-source="post: 1320257" data-attributes="member: 221382"><p>Here is what i have made with geektool,</p><p><img src="http://i1086.photobucket.com/albums/j448/applemaniac2/ScreenShot2011-11-02at103624PM.png" alt="" class="fr-fic fr-dii fr-draggable " style="" /></p><p>Here Are The Scripts i used</p><p>Calendar: [CODE]cal[/CODE]</p><p>day: [CODE]date +%A[/CODE]</p><p>date:[CODE]date +%d[/CODE] </p><p>Month: [CODE]date +%B[/CODE]</p><p>time :[CODE]date "+%l:%M"[/CODE]</p><p>Am/Pm: [CODE]date +%p[/CODE]</p><p>Uptime: [CODE]uptime | awk '{print "" $3 }' | sed -e 's/.$//g';[/CODE]</p><p>hard drive space: [CODE]df -hl | grep disk1 | awk '{print $4 }'[/CODE]</p><p>hard drive space percentage : [CODE]df -hl | grep disk1 | awk '{print $5 }'[/CODE]</p><p>Cpu : [CODE]#!/bin/sh</p><p></p><p># in 10.5 use the following:</p><p>#cpu=$(top -l 1| grep 'Load Avg' | awk '{print $12, $13}')</p><p># in 10.6 use the following:</p><p>cpu=$(top -l 1|grep 'CPU usage' | awk '{print $7}')</p><p>inactivemem=$(top -l 1 | awk '/PhysMem/ {print $6}')</p><p>freemem=$(top -l 1 | awk '/PhysMem/ {print $10}')</p><p></p><p>if [ "$(echo ${inactivemem} | egrep '.*G$')" ]; then</p><p> inactivemem=$(echo ${inactivemem} | cut -d 'G' -f 1)</p><p> let inactivemem=${inactivemem}*1024</p><p>else</p><p> inactivemem=$(echo ${inactivemem} | cut -d 'M' -f 1)</p><p>fi</p><p></p><p>if [ "$(echo ${freemem} | egrep '.*G$')" ]; then</p><p> freemem=$(echo ${freemem} | cut -d 'G' -f 1)</p><p> let freemem=${freemem}*1024</p><p>else</p><p> freemem=$(echo ${freemem} | cut -d 'M' -f 1)</p><p>fi</p><p></p><p>let freemem=${freemem}+${inactivemem}</p><p></p><p>freemem=$(echo "scale=2; ${freemem} / 1024" | bc)</p><p>uptime=$(uptime | awk '{print $3 " " $4 " " $5 }' | sed -e 's/.$//g')</p><p></p><p></p><p>echo ${cpu}</p><p></p><p>[/CODE]</p><p>RAM: [CODE]top -l 1 | awk '/PhysMem/ {print "" $8 " "}' ;[/CODE]</p><p>for the batter percentage and weather i used yahoo widgets here are the links to them</p><p>Weather: <a href="http://www.widgets.yahoo.com/widgets/widescapeweather" target="_blank">http://www.widgets.yahoo.com/widgets/widescapeweather</a></p><p>battery: <a href="http://www.widgets.yahoo.com/widgets/wdscp-battery" target="_blank">http://www.widgets.yahoo.com/widgets/wdscp-battery</a></p><p>The font is available for download here: <a href="http://www.dafont.com/comic-book.font" target="_blank">http://www.dafont.com/comic-book.font</a> </p><p></p><p></p><p></p><p>the hard drive space is edited for mac osx lion use for the snow leopard and lower here it is: [CODE] df -h | grep disk0s2 | awk '{print $4 }' </p><p>[/CODE]</p></blockquote><p></p>
[QUOTE="applemaniac, post: 1320257, member: 221382"] Here is what i have made with geektool, [IMG]http://i1086.photobucket.com/albums/j448/applemaniac2/ScreenShot2011-11-02at103624PM.png[/IMG] Here Are The Scripts i used Calendar: [CODE]cal[/CODE] day: [CODE]date +%A[/CODE] date:[CODE]date +%d[/CODE] Month: [CODE]date +%B[/CODE] time :[CODE]date "+%l:%M"[/CODE] Am/Pm: [CODE]date +%p[/CODE] Uptime: [CODE]uptime | awk '{print "" $3 }' | sed -e 's/.$//g';[/CODE] hard drive space: [CODE]df -hl | grep disk1 | awk '{print $4 }'[/CODE] hard drive space percentage : [CODE]df -hl | grep disk1 | awk '{print $5 }'[/CODE] Cpu : [CODE]#!/bin/sh # in 10.5 use the following: #cpu=$(top -l 1| grep 'Load Avg' | awk '{print $12, $13}') # in 10.6 use the following: cpu=$(top -l 1|grep 'CPU usage' | awk '{print $7}') inactivemem=$(top -l 1 | awk '/PhysMem/ {print $6}') freemem=$(top -l 1 | awk '/PhysMem/ {print $10}') if [ "$(echo ${inactivemem} | egrep '.*G$')" ]; then inactivemem=$(echo ${inactivemem} | cut -d 'G' -f 1) let inactivemem=${inactivemem}*1024 else inactivemem=$(echo ${inactivemem} | cut -d 'M' -f 1) fi if [ "$(echo ${freemem} | egrep '.*G$')" ]; then freemem=$(echo ${freemem} | cut -d 'G' -f 1) let freemem=${freemem}*1024 else freemem=$(echo ${freemem} | cut -d 'M' -f 1) fi let freemem=${freemem}+${inactivemem} freemem=$(echo "scale=2; ${freemem} / 1024" | bc) uptime=$(uptime | awk '{print $3 " " $4 " " $5 }' | sed -e 's/.$//g') echo ${cpu} [/CODE] RAM: [CODE]top -l 1 | awk '/PhysMem/ {print "" $8 " "}' ;[/CODE] for the batter percentage and weather i used yahoo widgets here are the links to them Weather: [URL="http://www.widgets.yahoo.com/widgets/widescapeweather"]http://www.widgets.yahoo.com/widgets/widescapeweather[/URL] battery: [URL="http://www.widgets.yahoo.com/widgets/wdscp-battery"]http://www.widgets.yahoo.com/widgets/wdscp-battery[/URL] The font is available for download here: [URL="http://www.dafont.com/comic-book.font"]http://www.dafont.com/comic-book.font[/URL] the hard drive space is edited for mac osx lion use for the snow leopard and lower here it is: [CODE] df -h | grep disk0s2 | awk '{print $4 }' [/CODE] [/QUOTE]
Verification
How many occurrences of a n-u-m-b-e-r between "d" and "f" in this example...(sdgs6ngklu3gd#f9%)?
Post reply
Forums
Apple Computing Products:
macOS - Apps and Programs
Geektool scripts
Top