I'm working on a python solution to this, need some more time. Wanted to let you know that someone is working on it and not leaving you hanging.
Wow thank you. I really appreciate it!
I'm working on a python solution to this, need some more time. Wanted to let you know that someone is working on it and not leaving you hanging.
#! /bin/bash
mkdir -p ~/Documents/FuelPrices
cd ~/Documents/FuelPrices
curl "http://m.gasbuddy.com/StationProfile.aspx?s=AibDFn%2fkZNc%3d&t=33020" -o "oakwoodprices.txt"
curl "http://m.gasbuddy.com/StationProfile.aspx?s=MVtn7QmOZDw%3d&t=33020" -o "cumberlandprices.txt"
curl "http://m.gasbuddy.com/StationProfile.aspx?s=Lab28UNbuoU%3d&t=33020" -o "bpprices.txt"
curl "http://m.gasbuddy.com/StationProfile.aspx?s=yyecGr%2bojLA%3d&t=33020" -o "citgo.txt"
curl "http://m.gasbuddy.com/StationProfile.aspx?s=il1ROWqGEa4%3d&t=33020" -o "shell.txt"
curl "http://m.gasbuddy.com/StationProfile.aspx?s=%2bzYZn0wkjAk%3d&t=33021" -o "mobil34.txt"
curl "http://m.gasbuddy.com/StationProfile.aspx?s=UVbB2sjc9Hw%3d" -o "mobil40stirling.txt"
curl "http://m.gasbuddy.com/StationProfile.aspx?s=jUaUcZDnbuw%3d" -o "chevron40.txt"
curl "http://m.gasbuddy.com/StationProfile.aspx?s=3wLwrvm77f8%3d&t=1+south+dania+beach+blvd+fl" -o "mobildania.txt"
#Regular
#awk#1 captures line # 126, awk#2 removes leading whitespace, tr removes linefeed
oakR=$(awk 'NR==126' ~/Documents/FuelPrices/oakwoodprices.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
cumbfarmR=$(awk 'NR==126' ~/Documents/FuelPrices/cumberlandprices.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
bpR=$(awk 'NR==126' ~/Documents/FuelPrices/bpprices.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
citgoR=$(awk 'NR==126' ~/Documents/FuelPrices/citgo.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
shellR=$(awk 'NR==126' ~/Documents/FuelPrices/shell.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
mobil34R=$(awk 'NR==126' ~/Documents/FuelPrices/mobil34.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
mobil40R=$(awk 'NR==126' ~/Documents/FuelPrices/mobil40stirling.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
chevronR=$(awk 'NR==126' ~/Documents/FuelPrices/chevron40.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
mobildaniaR=$(awk 'NR==126' ~/Documents/FuelPrices/mobildania.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
#Special
oakSP=$(awk 'NR==153' ~/Documents/FuelPrices/oakwoodprices.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
cumbfarmSP=$(awk 'NR==153' ~/Documents/FuelPrices/cumberlandprices.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
bpSP=$(awk 'NR==153' ~/Documents/FuelPrices/bpprices.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
citgoSP=$(awk 'NR==153' ~/Documents/FuelPrices/citgo.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
shellSP=$(awk 'NR==153' ~/Documents/FuelPrices/shell.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
mobil34SP=$(awk 'NR==153' ~/Documents/FuelPrices/mobil34.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
mobil40SP=$(awk 'NR==153' ~/Documents/FuelPrices/mobil40stirling.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
chevronSP=$(awk 'NR==153' ~/Documents/FuelPrices/chevron40.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
mobildaniaSP=$(awk 'NR==153' ~/Documents/FuelPrices/mobildania.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
#Super
oakSU=$(awk 'NR==180' ~/Documents/FuelPrices/oakwoodprices.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
cumbfarmSU=$(awk 'NR==180' ~/Documents/FuelPrices/cumberlandprices.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
bpSU=$(awk 'NR==180' ~/Documents/FuelPrices/bpprices.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
citgoSU=$(awk 'NR==180' ~/Documents/FuelPrices/citgo.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
shellSU=$(awk 'NR==180' ~/Documents/FuelPrices/shell.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
mobil34SU=$(awk 'NR==180' ~/Documents/FuelPrices/mobil34.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
mobil40SU=$(awk 'NR==180' ~/Documents/FuelPrices/mobil40stirling.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
chevronSU=$(awk 'NR==180' ~/Documents/FuelPrices/chevron40.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
mobildaniaSU=$(awk 'NR==180' ~/Documents/FuelPrices/mobildania.txt|awk '{ sub(/^[ \t]+/, ""); print }'| tr '\r' ' ')
#Diesel
#awk#1 captures line # 126, awk#2 removes leading whitespace, awk#3 removes trailing whitespace, tr removes linefeed
oakD=$(awk 'NR==207' ~/Documents/FuelPrices/oakwoodprices.txt|awk '{ sub(/^[ \t]+/, ""); print }'| awk '{$1=$1};1' |tr '\r' ' ')
citgoD=$(awk 'NR==207' ~/Documents/FuelPrices/citgo.txt|awk '{ sub(/^[ \t]+/, ""); print }'|awk '{$1=$1};1' | tr '\r' ' ')
mobil40D=$(awk 'NR==207' ~/Documents/FuelPrices/mobil40stirling.txt|awk '{ sub(/^[ \t]+/, ""); print }'| awk '{$1=$1};1' |tr '\r' ' ')
chevronD=$(awk 'NR==207' ~/Documents/FuelPrices/chevron40.txt|awk '{ sub(/^[ \t]+/, ""); print }'| awk '{$1=$1};1' |tr '\r' ' ')
printf " %-6s %-6s %-6s %-6s %-6s %-6s %-6s %-6s %-6s\n" "Oak" "Cumb" "BP" "Citg" "Shell" "Mob34" "Mob40" "Chev" "Mob1"
printf "Reg %-6s %-6s %-6s %-6s %-6s %-6s %-6s %-6s %-6s\n" "$oakR" "$cumbfarmR" "$bpR" "$citgoR" "$shellR" "$mobil34R" "$mobil40R" "$chevronR" "$mobildaniaR"
printf "Spc %-6s %-6s %-6s %-6s %-6s %-6s %-6s %-6s %-6s\n" "$oakSP" "$cumbfarmSP" "$bpSP" "$citgoSP" "$shellSP" "$mobil34SP" "$mobil40SP" "$chevronSP" "$mobildaniaSP"
printf "SU+ %-6s %-6s %-6s %-6s %-6s %-6s %-6s %-6s %-6s\n" "$oakSU" "$cumbfarmSU" "$bpSU" "$citgoSU" "$shellSU" "$mobil34SU" "$mobil40SU" "$chevronSU" "$mobildaniaSU"
printf "Die %-6s %-6s %-6s %-6s %-6s %-6s %-6s %-6s %-6s\n" "$oakD" "" "" "$citgoD" "" "" "$mobil40D" "$chevronD"
exit 0
Ah ok, well that's easily enough done.
For condition...
Code:curl --silent "http://weather.yahooapis.com/forecastrss?p=USPA0730&u=f" | grep -E '(Current Conditions:|F<BR)' | sed -e 's/Current Conditions://' -e 's/<br \/>//' -e 's/<b>//' -e 's/<\/b>//' -e 's/<BR \/>//' -e 's/<description>//' -e 's/<\/description>//' | cut -f 1 -d ","
For temperature...
Code:curl --silent "http://weather.yahooapis.com/forecastrss?p=USPA0730&u=f" | grep -E '(Current Conditions:|F<BR)' | sed -e 's/Current Conditions://' -e 's/<br \/>//' -e 's/<b>//' -e 's/<\/b>//' -e 's/<BR \/>//' -e 's/<description>//' -e 's/<\/description>//' | cut -f 2 -d ","
I've recently updated to Lion from a fresh install and I've basically gotten Geektools all setup. But I can't get my dock background to go away. I remember it involved deleting/replacing the .png files that the system uses to render the dock. I've been looking around and can only find the unhelpful suggestion to purchase a program for 10 bucks.
Basically, I have everything back the way I want it with the exception of the dock:
[url=http://img818.imageshack.us/img818/1630/screenshot20110803at634.th.jpg]Image[/URL]
I am soooo lost. i downloaded Geektool 3 and would love if I could have a todo list in one corner and date/time in another. is this possible? I just don't know what to do![]()
Easily done mate, just be a little more specific on how you want them to look like! I know 124 pages sounds like a lot to browse through but truly it's mostly either todo/calendar/date&time/stocks geeklets, so just pick some random pages and you should find a desktop with a style that interests you! Then knock back here if the post with the desktop and the code doesn't help you
PS: Tag, thanks for the help mate you're a GENIOUS.
I would like to do either this one http://www.macosxtips.co.uk/geeklets/productivity/to-do-list-from-ical/ or
http://macmembrane.com/use-geektool-to-display-taskpaper-lists-on-your-desktop/ this for todo. I've downloaded geek tool and a geek let but I can't get it to work![]()
echo "What ever you what to say"Hi, what is the geektool script if I just want to have a message/text displayed?
echo "What ever you what to say"
echo is the command
The text between the quote marks will be displayed
#!/usr/bin/osascript
on run
set info to ""
tell application "System Events"
set num to count (every process whose name is "iTunes")
end tell
if num > 0 then
tell application "iTunes"
if player state is playing then
set how to rating of current track
set how to how / 20 as integer
set star to {"★"}
set infoitems to {}
set starnum to 0
repeat
set infoitems to infoitems & star
set starnum to starnum + 1
if starnum = how then exit repeat
end repeat
set info to infoitems as string
end if
end tell
end if
return info
end run
on run
set info to ""
tell application "System Events"
set num to count (every process whose name is "iTunes")
end tell
if num > 0 then
tell application "iTunes"
if player state is playing then
set how to rating of current track
set how to how / 20 as integer
set star to {"★"}
set infoitems to {}
set starnum to 0
repeat
if how < 1 then exit repeat
set infoitems to infoitems & star
set starnum to starnum + 1
if starnum = how then exit repeat
end repeat
set info to infoitems as string
if info = "" then set info to "Not rated"
end if
end tell
end if
return info
end run
@ caaalebbb Try this.
Code:on run set info to "" tell application "System Events" set num to count (every process whose name is "iTunes") end tell if num > 0 then tell application "iTunes" if player state is playing then set how to rating of current track set how to how / 20 as integer set star to {"★"} set infoitems to {} set starnum to 0 repeat if how < 1 then exit repeat set infoitems to infoitems & star set starnum to starnum + 1 if starnum = how then exit repeat end repeat set info to infoitems as string if info = "" then set info to "Not rated" end if end tell end if return info end run
on run
set info to ""
tell application "System Events"
set num to count (every process whose name is "iTunes")
end tell
if num > 0 then
tell application "iTunes"
if player state is playing then
if rating of current track > 1 then
set how to rating of current track
set how to how / 20 as integer
set star to {"★"}
set infoitems to {}
set starnum to 0
repeat
set infoitems to infoitems & star
set starnum to starnum + 1
if starnum = how then exit repeat
end repeat
set info to infoitems as string
else
set info to played count of current track
end if
end if
end tell
end if
return info
end run
error Cant make \"Macintosh HD:Users:username:Pictures:iTunes Artwork:From iTunes:albumArt.pict\" into type file specification." number -1700 from "Macintosh HD:Users:username:Pictures:iTunes Artwork:From iTunes:albumArt.pict" to file specification
heres a cool script i found searching for a facebook RSS feed... (totally unrelated)
it puts the itunes artwork on your desktop! i've been wanting to do this forever!
Code:-- Paths and stuff set ArtworkFromiTunes to ((path to home folder) as text) & ¬ "Pictures:iTunes Artwork:From iTunes:albumArt.pict" as alias set iTunesArtwork to ((path to home folder) as text) & ¬ "Pictures:iTunes Artwork:From iTunes:albumArt.pict" set DefaultArtwork to ((path to home folder) as text) & ¬ "Pictures:iTunes Artwork:Default:albumArt.pict" set displayArtwork to ((path to home folder) as text) & ¬ "Pictures:iTunes Artwork:albumArt.pict" -- Unix versions of the above path strings set unixITunesArtwork to the quoted form of POSIX path of iTunesArtwork set unixDefaultArtwork to the quoted form of POSIX path of DefaultArtwork set unixDisplayArtwork to the quoted form of POSIX path of displayArtwork set whichArt to "blank" tell application "System Events" if exists process "iTunes" then -- iTunes is running tell application "iTunes" if player state is playing then -- iTunes is playing set aLibrary to name of current playlist -- Name of Current Playlist set aTrack to current track set aTrackArtwork to null if (count of artwork of aTrack) ≥ 1 then -- there's an album cover "Running and playing and art" set aTrackArtwork to data of artwork 1 of aTrack set fileRef to ¬ (open for access ArtworkFromiTunes with write permission) try set eof fileRef to 512 write aTrackArtwork to fileRef starting at 513 close access fileRef on error errorMsg try close access fileRef end try error errorMsg end try tell application "Finder" to ¬ set creator type of ArtworkFromiTunes to "????" set whichArt to "iTunes" end if end if end tell end if end tell if whichArt is "iTunes" then do shell script "ditto -rsrc " & unixITunesArtwork & space & unixDisplayArtwork else do shell script "ditto -rsrc " & unixDefaultArtwork & space & unixDisplayArtwork end if
its in AppleScript and you have to do a few steps before it works (make a folder in ~/Pictures)
more info here! http://www.leancrew.com/all-this/2007/06/album-art-with-geektool/
still havent found anything on a facebook geeklet...
so if you have something that actually works, let me know! (and that doesnt use automator...)
Here it goes,
Code:tell application "Finder" set AppleScript's text item delimiters to "" set power to every paragraph of (do shell script "networksetup -getairportpower Airport Extreme") if (power as string) contains "On" then set airport to do shell script "networksetup -getairportnetwork Airport Extreme" set AppleScript's text item delimiters to ": " set airport to text item 2 of airport as string set AppleScript's text item delimiters to "" else set airport to "Aiport Power Off" end if -- display signal strength set strength_curfolder to "mac hd:users:tom:documents:geektool:airport strength:current" set strength_pngfolder to "mac hd:users:tom:documents:geektool:airport strength" set AppleScript's text item delimiters to "" set strength to (do shell script "/System/Library/PrivateFrameworks/Apple80211.framework/Resources/airport --getinfo") if (count of every paragraph of (strength as string)) is greater than 2 then set strength to paragraph 1 of (strength as string) set AppleScript's text item delimiters to "-" set strength to text item 2 of strength set AppleScript's text item delimiters to "" set strength_percent to character 1 of (((strength / 96) * 3) as string) -- display dialog ((strength / 96) * 3) if (name of item 1 of folder strength_curfolder) as string is not equal to ((strength_percent as string) & ".png") then move item 1 of folder strength_curfolder to folder strength_pngfolder move item (strength_pngfolder & ":" & (strength_percent as string) & ".png") to folder strength_curfolder end if else if (name of item 1 of folder strength_curfolder) as string is not equal to ("00.png") then move item 1 of folder strength_curfolder to folder strength_pngfolder move item (strength_pngfolder & ":" & ("00.png")) to folder strength_curfolder end if end if --data voor geektool return airport end tell
You need to change following paths in the applescript
1. strength_curfolder (this one goes to the folder with current image to be displayed)
2. strength_pngfolder (this one goes to the folder where all the images are located)
Geektool,
shell geeklet: osascript (unix path to script)
image geeklet: path to current image folder (not the image itself but just the folder where it's in)
example: in geektool you should see something like this "file://localhost/Users/tom/Documents/geektool/airport strength/current/"
What's your scale of displaying the current airport strength?
mine is 3 this means, I have 3 bars that will change according to the signal.
I only use the first character from my calculation so my files name are like this,
0.png (1 stripe), 1.png (2 stripes), 2.png (3 stripes (=good signal)), 00.png (0 stripes)
If you want an example you can check out my geektool setup
if you have questions then I'll be glad to answer
enjoy
hey guys. i really only know how to code html and css because i took a class on it. how would i be able to code something like the windows 8 tiles from here. i don't plan on switching back to windows but think it is a neat idea. any help?
http://www.unplggd.com/unplggd/roundup/geektool-151524
its the second image btw, not the default sand one