Let me know :) For now, this is the code: # 'weatherbang' - originally an openbox conky script # Optionally just use brew: 'brew install jq' # A TON of this was stolen directly from Frederic Cambus, thanks! # add all of this as a shell script for GeekTool and configure as needed. Temperature=$(printf '%.0f' $(echo $weather | /usr/local/bin/jq '.main.temp'))Ĭondition=$(echo $weather | /usr/local/bin/jq -r '.weather.main')Įcho "$city - $condition: $temperature $unit" # Parse the latitude and longitude into their own values Latlong=$(echo $ipinfo | /usr/local/bin/jq -r '.loc') # Otherwise comment above line, uncomment here for celcius: #Cool desktop themes for geektool install This is part of my first geektool desktop attempt and I was getting increasingly frustrated with other weather geeklets not working for me. I thought that there had to be an easier way around this! It was always the weather icon that failed where it was attempting to scrape the icon from the Yahoo weather site. I decided to take a look at the RSS feed used for the weather description and saw a section for the weather code which relates to the yahoo weather APIs and references the weather description. This got me thinking that I could use these codes to load an image in a geeklet rather than trying to download the image from Yahoo that was used in the other method. I found some amazing weather icons which were created based on the Yahoo weather codes. You can download the icons from MerlinTheRed's DeviantArt page - Instructions Attachmentsĭownload all of the attachments below and save them to a new folder called 'weather'ĭownload the icons from MerlinTheRed's DeviantArt page You will need these for these geeklets to work. #Cool desktop themes for geektool download Place the extracted 'plain_weather' folder in your new 'weather' folder with the other glets and files. Go to Yahoo weather and search for the weather in your area. Open the weather image glet and point the 'yourpath' to the location of the temp.png file in the weather folder and save the changes. Open and edit the weatherCode.scpt, replace the 44418 with the number for your locationĬhange the directoryPath to the location of the new 'weather' folder and save the changes You can remove the symbol of the description by removing the following part of the script:Īmmend the 'yourpath' to point to the location of the weather folder where the weatherCode.scpt resides WeatherCode AppleScript Open and edit the weather description glet and replace 44418 with the number for your location and save the glet. To change the icon style open the weatherCode.scpt and change the folder name 'flat_white' to one of the other folder names available under the 'plain_weather' directory. Just change the 'c' at the end of the url to F for fahrenheit. The glets are set to update every 3600 seconds simply change the frequency if desired shorter or longer. I think this is everything.On this Page you can find a couple of my Desktop Scripts that can be used with GeekTool or NerdTool or Conky.Įssentially, these are small shell scripts that display bits of information: Current free HDD space, Temperature, Weather, etc. #Cool desktop themes for geektool download.#Cool desktop themes for geektool update.#Cool desktop themes for geektool install.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |