I'm rather new in Geektool.
I can manage time, day, hour, itunes,...
but I still can't manage how I can get the weather on my desktop,
now I have the temperature and, at the time, Mostly Cloudy.
But the picture of the clouds and sun or moon don't work for me.
In a earlier post I found this
To get the image to show up on your desktop use this script:
Code:
file:///tmp/weather.png
But where do you have to write this script, in a separate shell or in the same?
And what URL do you need tot put in the script the same that I used (the citycode in yahoo)?
curl --silent "YOUR_YAHOO_URL_ADDRESS" | grep "forecast-icon" | sed "s/.*background\:url(\'\(.*\)\')\;\ _background.*/\1/" | xargs curl --silent -o /var/tmp/weather_image.png\
file://localhost/var/tmp/weather_image.png
Excellent!
Just the kind of information I was looking for
Thank you muchly
# set this to the maximum number of dashes the progress meter will reach
set maxNumberOfDashes to 184
tell application "System Events" to set iTunesIsRunning to (name of processes) contains "iTunes"
if iTunesIsRunning is false then
return ""
end if
tell application "System Events"
set powerCheck to ((application processes whose (name is equal to "iTunes")) count)
if powerCheck = 0 then
return ""
end if
end tell
if iTunesIsRunning is true then
set trackPosition to 0
set trackLength to 0
set theStream to ""
tell application "iTunes"
try
set playerstate to (get player state)
end try
if playerstate = paused then
set trackPaused to " (paused)"
else
set trackPaused to ""
end if
if playerstate = stopped then
#return "Stopped"
end if
set trackID to the current track
set trackPosition to the player position
set trackLength to the duration of trackID
set theStream to the current stream title as text
end tell
if theStream is not "missing value" then
set totalData to ""
repeat maxNumberOfDashes times
set totalData to "" & totalData
end repeat
return totalData
end if
set numberOfDashes to (trackPosition / trackLength) * maxNumberOfDashes as integer
set totalData to ""
repeat numberOfDashes times
set totalData to "" & totalData
end repeat
return totalData
end if
osascript /Path/To/The/File/position.scpt
Sorry about the oversized image before
Here is my icalbuddy settings
/usr/local/bin/icalBuddy -nc -sd -b "" -ps "| - |" -ss "" -sed -eep location,notes,url eventsToday+2
No piping through sed required.
I also adjusted the locale file to capitalize the titles.
you're wellcomeThanks to the guy who created that nerdtool package.
this is for New York:Would anyways have the code to just show "41〫" instead of "41〬F" ?
curl --silent "http://weather.yahooapis.com/forecastrss?p=USNY0996&u=f" | grep -E '(Current Conditions:|[A-Z]<BR)' | sed -e 's/Current Conditions://' -e 's/<br \/>//' -e 's/<b>//' -e 's/<\/b>//' -e 's/<BR \/>//' -e 's/[A-Z a-z]*, //' -e 's/\(.*\) F/\1°/' -e 's/\(.*\) C/\1°/' | tail -n1
for my macbook internal hard drive i use this one " df -h | grep disk0s2 | awk '{print "Macintosh HD:", $4, "remaining"}' " but i am unable to use it with my time machine hard drive as the drive ID of time machine is afp_0SIfZQ0SNssx00jkPL0Pyetl-1.2d000003 and the last digit (i.e 3 in our case) is changing after each restart. So is there any way to get the free space by using the path to the mounted volume (/Volumes/Time capsule) instead of using the diskid?
df -h | grep 0SIfZQ0SNssx | awk '{print "Time Machine HD:", $4, "remaining"}'
df -h | grep 'TM drive here' | awk '{print "Time Machine HD:",$4,"remaining"}'
Perfect tutorial but I am having one problem. How do I get rid of the odd character between the number and degree.
![]()
I took the degree symbol off of mine because I couldn't get that strange character to go away. I think it has something to do with the font, but I haven't been able to figure it out.
Try changing the text encoding from ASCII to UTF-8.
I was going to ask the same question.How do I change the character code
I was going to ask the same question.![]()
does anyone knw how to change the color of the event time like the one in the link? http://minimalmac.com/post/221196886/desktop-10-23-2009-via-patrickrhone-this-got-a
ive been having trouble looking for a code or script for this one. i only have this as a script: how can i change the time color to green?
/usr/local/bin/icalBuddy -nc -b " + " eventsToday | sed -e "s/*/+ /" | sed -e "s/!/!!/"
I can't find that anywhere in Geektool 2. I don't think that's an option.I'm currently using NerdTool but I'm pretty sure you can change the encoding in Geektool also, I just don't remember where it is for sure.
I am still using GT2
![]()
It has nothing to do with the code placed in geektool and everything to do with the icalBuddyConfig.plist. I remember looking at it and fooling around a bit when I did mine, but I can;t recall right now and I don't have the time to dig through it. If it is not answered by tomorrow afternoon I can look into it a little more.