pax_global_header00006660000000000000000000000064131225535360014517gustar00rootroot0000000000000052 comment=511719b71c4278f8cef91fac89380bbb85253861 ansiweather-1.11/000077500000000000000000000000001312255353600137535ustar00rootroot00000000000000ansiweather-1.11/AUTHORS000066400000000000000000000001461312255353600150240ustar00rootroot00000000000000AnsiWeather is developed by: Frederic Cambus Site: https://www.cambus.net ansiweather-1.11/ChangeLog000066400000000000000000000064451312255353600155360ustar00rootroot00000000000000AnsiWeather 1.11 (2017-06-21) - Unicode symbols display is now off by default - Shorten default greeting text: "Current weather" => "Weather" AnsiWeather 1.10 (2017-02-16) - Add a '-v' option to show version number - Exit with error code when an unknown option is invoked - Make wind direction customizable AnsiWeather 1.09 (2016-10-18) - Allow toggling display of wind, humidity, and pressure data (Thanks John Kaczmarek) - The -h option does not show help anymore, as everything is available in the manpage - Remove extraneous whitespace before daylight data - Rename 'daylight' variable to 'show_daylight' for consistency with the newly introduced options (user configuration files must be updated) - Various documentation and manpage updates and reformatting AnsiWeather 1.08 (2016-07-26) - Use env printf instead of hardcoding printf path - Added a $forecast_text variable allowing to customize forecast text - Relicensed under the BSD 2-Clause license AnsiWeather 1.07 (2016-01-19) - Exit with non-zero return code on failure - Documentation updates - Added a manual page AnsiWeather 1.06 (2015-10-30) - Added support for OpenWeatherMap API keys - Changed curl options from '-s' to '-sf' to fail silently on server errors - Removing auto location helper, user location must now be explicitly set - Changed default city to Rzeszow, Poland - Changing rain and thunderstorm icons default colors to white and yellow - Documentation updates AnsiWeather 1.05 (2015-09-27) - Fixes for numeric translation on NetBSD (Thanks Kamil Rytarowski) - Use xargs printf construct to avoid hardcoding path to external printf command (Thanks Kamil Rytarowski) - Use '/bin/sh' shebang instead of '/usr/bin/env sh' for portability reasons (Thanks Kamil Rytarowski) - Replacing spaces by underscores in location name before calling the weather API - Force bc to always return integers for wind directions (Thanks Lornix) - Documentation updates AnsiWeather 1.04 (2015-09-10) - Added a '-a' option to toggle ANSI colors display - Daylight option in the example configuration file now default to false to match program default - Better formatting for usage display - Documentation updates AnsiWeather 1.03 (2015-09-08) - Removed dependency on Bash, AnsiWeather is now using plain sh - Detect all numeric locations and switching from 'q' to 'id' API query parameter in this case - Do not attempt to convert pressure data to imperial units in forecast mode (Bugfix) - Added a '-h' option to display usage - Parse arguments before setting options (Thanks Lucas Hoffmann) - Documentation updates - Linting and minor fixes AnsiWeather 1.02 (2015-05-09) - Documentation updates - Populated ChangeLog - Allow overriding default config file location using ANSIWEATHERRC environment variable (Thanks Lucas Hoffmann) - Check if 'bc' is installed before starting AnsiWeather 1.01 (2015-03-16) - Add ability to store options in config file (Thanks Aaron Bieber) - Automatic location detection (Thanks Michael Price) - Showing wind direction and speed - Add ability to display upcoming weekly forecast (Thanks Michael Reinhardt) - Add ability to display daylight data (Thanks Roy Hodgman) - Allow custom geolocation server to be set (Thanks Aaron Bieber) - Removed dependency on seq AnsiWeather 1.00 (2013-10-19) - Initial release ansiweather-1.11/LICENSE000066400000000000000000000024411312255353600147610ustar00rootroot00000000000000Copyright (c) 2013-2017, Frederic Cambus All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ansiweather-1.11/README.md000066400000000000000000000122621312255353600152350ustar00rootroot00000000000000## Description AnsiWeather is a Shell script for displaying the current weather conditions in your terminal, with support for ANSI colors and Unicode symbols. ![AnsiWeather Screenshot][1] Weather data comes from the `OpenWeatherMap` free weather API. ## Requirements AnsiWeather requires the following dependencies: - A command to fetch HTTP data such as FTP, cURL or wget - [jq][2] (lightweight and flexible command-line JSON processor) - [bc][3] (arbitrary precision numeric processing language), for doing float arithmetic ## Installation After cloning the repository, simply invoke the script by typing: ./ansiweather AnsiWeather packages are available for: ### OpenBSD pkg_add ansiweather ### Pkgsrc (NetBSD, SmartOS, Mac OS X, etc.) pkgin install ansiweather ### FreeBSD pkg install ansiweather ### Debian apt-get install ansiweather ### Homebrew (Mac OS X) brew install ansiweather ## Usage ### Synopsis ansiweather [-F] [-l location] [-u system] [-f days] [-a value] [-s value] [-k key] [-w value] [-h value] [-p value] [-d value] ### Options -l location Specify location -u system Specify unit system to use ( metric or imperial ) -f days Toggle forecast mode for the specified number of upcoming days -F Toggle forecast mode for the next five days -a value Toggle ANSI colors display ( true or false ) -s value Toggle symbols display ( true or false ) -k key Specify API key -w value Toggle wind data display ( true or false ) -h value Toggle humidity data display ( true or false ) -p value Toggle pressure data display ( true or false ) -d value Toggle daylight data display ( true or false ) ### Examples Display forecast using metric units for the next five days (showing symbols and daylight data) for Rzeszow, Poland: ansiweather -l Rzeszow,PL -u metric -s true -f 5 -d true ## Configuration The default config file is ~/.ansiweatherrc. The environment variable ANSIWEATHERRC can be set to override this. The following configuration options (detailed below) are available and should be set according to your location and preferences. Example: `~/.ansiweatherrc` location:Rzeszow,PL fetch_cmd:ftp -V -o - units:metric show_daylight:true The file `ansiweatherrc.example` contains all available configuration variables. ### Location Location format is `city,CC` where `CC` is a two-letter ISO 3166-1 alpha-2 country code. A list of country codes is available [here][4]. Alternatively, it's also possible to specify locations by their ID, a city list is available [here][5]. In case no location is specified, AnsiWeather will fallback to the default location. Example: `Rzeszow,PL` location:Rzeszow,PL ### Fetch Command Various tools can be used to fetch data: `curl`, `wget`, `ftp`. Please note that `ftp` flags and options might differ among implementations and versions, and the example provided here is known to work only on OpenBSD, NetBSD and Mac OS X. Example: `curl -sf` fetch_cmd:curl -sf Example: `wget -qO-` fetch_cmd:wget -qO- Example: `ftp -V -o -` fetch_cmd:ftp -V -o - Default: `curl -sf` ### System of Units Both `metric` and `imperial` systems are supported. units:metric Default: `metric` ### Display ANSI sequences Toggle ANSI sequences display. Value can be either `true` (requires an ANSI capable display) or `false`. ansi:true Default: `true` ### Display symbols Toggle Unicode symbols display. Value can be either `true` (requires a Unicode capable display) or `false`. symbols:true Default: `false` Symbols can be configured or replaced by custom text using the following configuration variables: `sun`, `moon`, `clouds`, `rain`, `fog`, `mist`, `haze`, `snow`, `thunderstorm`. ### Display forecast Show upcoming forecast for the next `N` days (for 0 <= N <= 7). `0` will show standard output. forecast:5 Default: `0` ### Display wind / humidity / pressure Toggle wind, humidity, and/or pressure display. Values can be either `true` or `false`. show_wind:true show_humidity:true show_pressure:true Default: `true` ### Display sunrise / sunset Toggle daylight display. Value can be either `true` or `false`. show_daylight:false Default: `false` ### Date and Time format Configure date and time format display. See Unix date formatting docs for details. dateformat:%a %b %d Default: `%a %b %d` timeformat:%b %d %r Default: `%b %d %r` ### OpenWeatherMap API key Specify an OpenWeatherMap API key. By default AnsiWeather uses its own key, but users can optionally get their own one by creating a free [OpenWeatherMap account][6]. api_key:85a4e3c55b73909f42c6a23ec35b7147 ## License AnsiWeather is released under the BSD 2-Clause license. See `LICENSE` file for details. ## Author AnsiWeather is developed by Frederic Cambus. - Site: https://www.cambus.net ## Resources GitHub: https://github.com/fcambus/ansiweather [1]: https://www.cambus.net/files/ansiweather/ansiweather.png [2]: http://stedolan.github.io/jq/ [3]: https://www.gnu.org/software/bc/ [4]: https://www.statdns.com/cctlds/ [5]: http://openweathermap.org/help/city_list.txt [6]: https://home.openweathermap.org/users/sign_up ansiweather-1.11/ansiweather000077500000000000000000000242731312255353600162230ustar00rootroot00000000000000#!/bin/sh ############################################################################### # # # AnsiWeather 1.11 # # Copyright (c) 2013-2017, Frederic Cambus # # https://github.com/fcambus/ansiweather # # # # Created: 2013-08-29 # # Last Updated: 2017-06-21 # # # # AnsiWeather is released under the BSD 2-Clause license. # # See LICENSE file for details. # # # ############################################################################### ###[ Configuration options ]################################################### LC_ALL=C; export LC_ALL config_file=${ANSIWEATHERRC:-~/.ansiweatherrc} get_config() { ret="" if [ -f "$config_file" ] then ret=$(grep "^$1:" "$config_file" | awk -F: '{print $2}') fi if [ "X$ret" = "X" ] then return 1 else echo "$ret" fi } fetch_cmd=$(get_config "fetch_cmd" || echo "curl -sf") ###[ Parse the command line ]################################################## # Get config options from command line flags while getopts l:u:f:Fa:s:k:w:h:p:d:v option do case "${option}" in l) location=${OPTARG};; u) units=${OPTARG};; f) forecast=${OPTARG};; F) forecast="5";; a) ansi=${OPTARG};; s) symbols=${OPTARG};; k) api_key=${OPTARG};; w) show_wind=${OPTARG};; h) show_humidity=${OPTARG};; p) show_pressure=${OPTARG};; d) show_daylight=${OPTARG};; v) echo "AnsiWeather 1.11" && exit 0;; \?) exit 64;; # EX_USAGE esac done ###[ Check if bc and jq are installed ]######################################## jqpath=$(which jq) if [ "$jqpath" = "" ] then echo "ERROR: Cannot find jq binary" exit 69 # EX_UNAVAILABLE fi bcpath=$(which bc) if [ "$bcpath" = "" ] then echo "ERROR: Cannot find bc binary" exit 69 # EX_UNAVAILABLE fi ###[ Set options that are not set from command line ]########################## # OpenWeatherMap API key [ -z "$api_key" ] && api_key=$(get_config "api_key" || echo "85a4e3c55b73909f42c6a23ec35b7147") # Location: example "Rzeszow,PL" [ -z "$location" ] && location=$(get_config "location" || echo "Rzeszow,PL") # System of Units: "metric" or "imperial" [ -z "$units" ] && units=$(get_config "units" || echo "metric") # Show forecast: How many days, example "5". "0" is standard output [ -z "$forecast" ] && forecast=$(get_config "forecast" || echo 0) # Display ANSI colors: "true" or "false" [ -z "$ansi" ] && ansi=$(get_config "ansi" || echo true) # Display symbols: "true" or "false" (requires a Unicode capable display) [ -z "$symbols" ] && symbols=$(get_config "symbols" || echo false) # Show wind: "true" or "false" [ -z "$show_wind" ] && show_wind=$(get_config "show_wind" || echo true) # Show humidity: "true" or "false" [ -z "$show_humidity" ] && show_humidity=$(get_config "show_humidity" || echo true) # Show pressure: "true" or "false" [ -z "$show_pressure" ] && show_pressure=$(get_config "show_pressure" || echo true) # Show daylight: "true" or "false" [ -z "$show_daylight" ] && show_daylight=$(get_config "show_daylight" || echo false) dateformat=$(get_config "dateformat" || echo "%a %b %d") timeformat=$(get_config "timeformat" || echo "%b %d %r") ###[ Colors and characters ]################################################### background=$(get_config "background" || echo "\033[44m") text=$(get_config "text" || echo "\033[36;1m") data=$(get_config "data" || echo "\033[33;1m") delimiter=$(get_config "delimiter" || echo "\033[35m=>") dashes=$(get_config "dashes" || echo "\033[34m-") ###[ Text Labels ]############################################################# greeting_text=$(get_config "greeting_text" || echo "Weather in") wind_text=$(get_config "wind_text" || echo "Wind") humidity_text=$(get_config "humidity_text" || echo "Humidity") pressure_text=$(get_config "pressure_text" || echo "Pressure") sunrise_text=$(get_config "sunrise_text" || echo "Sunrise") sunset_text=$(get_config "sunset_text" || echo "Sunset") forecast_text=$(get_config "forecast_text" || echo "forecast") ###[ Unicode Symbols for icons ]############################################### sun=$(get_config "sun" || echo "\033[33;1m\xe2\x98\x80") moon=$(get_config "moon" || echo "\033[36m\xe2\x98\xbd") clouds=$(get_config "clouds" || echo "\033[37;1m\xe2\x98\x81") rain=$(get_config "rain" || echo "\033[37;1m\xe2\x98\x94") fog=$(get_config "fog" || echo "\033[37;1m\xe2\x96\x92") mist=$(get_config "mist" || echo "\033[34m\xe2\x96\x91") haze=$(get_config "haze" || echo "\033[33m\xe2\x96\x91") snow=$(get_config "snow" || echo "\033[37;1m\xe2\x9d\x84") thunderstorm=$(get_config "thunderstorm" || echo "\033[33;1m\xe2\x9a\xa1") ###[ Fetch Weather data ]###################################################### api_cmd=$([ "$forecast" != 0 ] && echo "forecast/daily" || echo "weather") if [ "$location" -gt 0 ] 2> /dev/null then # Location is all numeric weather=$($fetch_cmd "http://api.openweathermap.org/data/2.5/$api_cmd?id=$location&units=$units&appid=$api_key") else # Location is a string location=$(echo "$location" | sed "s/ /_/g") weather=$($fetch_cmd "http://api.openweathermap.org/data/2.5/$api_cmd?q=$location&units=$units&appid=$api_key") fi if [ -z "$weather" ] then echo "ERROR: Cannot fetch weather data" exit 75 # EX_TEMPFAIL fi status_code=$(echo "$weather" | jq -r '.cod' 2>/dev/null) if [ "$status_code" != 200 ] then echo "ERROR: Cannot fetch weather data for the given location" exit 69 # EX_UNAVAILABLE fi ###[ Process Weather data ]#################################################### epoch_to_date() { if date -j -r "$1" +"%a %b %d" > /dev/null 2>&1; then # BSD ret=$(date -j -r "$1" +"$dateformat") else # GNU ret=$(date -d "@$1" +"$dateformat") fi echo "$ret" } if [ "$forecast" != 0 ] then city=$(echo "$weather" | jq -r '.city.name') flength=$(echo "$weather" | jq '.list | length') forecast=$([ "$forecast" -gt "$flength" ] && echo "$flength" || echo "$forecast") else city=$(echo "$weather" | jq -r '.name') temperature=$(echo "$weather" | jq '.main.temp' | xargs printf "%.0f") humidity=$(echo "$weather" | jq '.main.humidity') pressure=$(echo "$weather" | jq '.main.pressure') sky=$(echo "$weather" | jq -r '.weather[0].main') sunrise=$(echo "$weather" | jq '.sys.sunrise') sunset=$(echo "$weather" | jq '.sys.sunset') wind=$(echo "$weather" | jq '.wind.speed') azimuth=$(echo "$weather" | jq '.wind.deg') fi ###[ Process Wind data ]####################################################### set -- $(get_config "wind_directions" || echo "N NNE NE ENE E ESE SE SSE S SSW SW WSW W WNW NW NNW") if [ "$forecast" = 0 ] then shift "$(echo "scale=0; ($azimuth + 11.25)/22.5 % 16" | bc)" direction=$1 fi ###[ Process Sunrise and Sunset data ]######################################### epoch_to_time() { if date -j -r "$1" +"%r" > /dev/null 2>&1; then # BSD ret=$(date -j -r "$1" +"$timeformat") else # GNU ret=$(date -d "@$1" +"$timeformat") fi echo "$ret" } if [ "$forecast" = 0 ] then if [ -n "$sunrise" ] then sunrise_time=$(epoch_to_time "$sunrise") fi if [ -n "$sunset" ] then sunset_time=$(epoch_to_time "$sunset") fi fi ###[ Set the period ]########################################################## now=$(date +%s) if [ "$forecast" != 0 ] then period="none" else if [ -z "$sunset" ] || [ -z "$sunrise" ] then period="day" elif [ "$now" -ge "$sunset" ] || [ "$now" -le "$sunrise" ] then period="night" else period="day" fi fi ###[ Set the scale ]########################################################### case $units in metric) scale="°C" speed_unit="m/s" pressure_unit="hPa" pressure=$(echo "$pressure" | xargs printf "%.0f") ;; imperial) scale="°F" speed_unit="mph" pressure_unit="inHg" if [ "$forecast" = 0 ] then pressure=$(echo "$pressure*0.0295" | bc | xargs printf "%.2f") fi ;; esac ###[ Set icons ]############################################################### get_icon() { case $1 in Clear) if [ $period = "night" ] then echo "$moon " else echo "$sun " fi ;; Clouds) echo "$clouds " ;; Rain) echo "$rain " ;; Fog) echo "$fog " ;; Mist) echo "$mist " ;; Haze) echo "$haze " ;; Snow) echo "$snow " ;; Thunderstorm) echo "$thunderstorm " ;; esac } ###[ Display current Weather ]################################################# if [ "$forecast" != 0 ] then output="$background$text $city $forecast_text $text$delimiter " i=0 while [ $i -lt "$forecast" ] do day=$(echo "$weather" | jq ".list[$i]") date=$(epoch_to_date "$(echo "$day" | jq -r '.dt')") low=$(echo "$day" | jq -r '.temp.min' | xargs printf "%.0f") high=$(echo "$day" | jq -r '.temp.max' | xargs printf "%.0f") icon="" if [ "$symbols" = true ] then sky=$(echo "$day" | jq -r '.weather[0].main') icon=$(get_icon "$sky") fi output="$output$text$date: $data$high$text/$data$low $scale $icon" if [ $i -lt $((forecast-1)) ] then output="$output$dashes " fi i=$((i + 1)) done else if [ "$symbols" = true ] then icon="$(get_icon "$sky")" fi output="$background$text $greeting_text $city $delimiter$data $temperature $scale $icon" if [ "$show_wind" = true ] then output="$output$dashes$text $wind_text $delimiter$data $wind $speed_unit $direction " fi if [ "$show_humidity" = true ] then output="$output$dashes$text $humidity_text $delimiter$data $humidity %% " fi if [ "$show_pressure" = true ] then output="$output$dashes$text $pressure_text $delimiter$data $pressure $pressure_unit " fi if [ "$show_daylight" = true ] then output="$output$dashes$text $sunrise_text $delimiter$data $sunrise_time $dashes$text $sunset_text $delimiter$data $sunset_time " fi fi if [ "$ansi" = true ] then env printf "$output\033[0m\n" else env printf "$output\n" | sed "s/$(printf '\033')\[[0-9;]*m//g" fi ansiweather-1.11/ansiweather.1000066400000000000000000000057361312255353600163620ustar00rootroot00000000000000.\" .\" Copyright (c) 2013-2017, Frederic Cambus .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions are met: .\" .\" * Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" .\" * Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" .\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" .\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS .\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR .\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF .\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS .\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN .\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" .Dd $Mdocdate: February 9 2017 $ .Dt ANSIWEATHER 1 .Os .Sh NAME .Nm ansiweather .Nd weather in terminal, with ANSI colors and Unicode symbols .Sh SYNOPSIS .Nm .Op Fl F .Op Fl l Ar location .Op Fl u Ar system .Op Fl f Ar days .Op Fl a Ar value .Op Fl s Ar value .Op Fl k Ar key .Op Fl w Ar value .Op Fl h Ar value .Op Fl p Ar value .Op Fl d Ar value .Op Fl v Ar value .Sh DESCRIPTION .Nm is a shell script for displaying the current weather conditions in a terminal, with support for ANSI colors and Unicode symbols. .Pp Weather data comes from the OpenWeatherMap free weather API. .Pp The options are as follows: .Bl -tag -width Ds .It Fl l Ar location Specify location .It Fl u Ar system Specify unit system to use ( .Ar metric or .Ar imperial ) .It Fl f Ar days Toggle forecast mode for the specified number of upcoming days .It Fl F Toggle forecast mode for the next five days .It Fl a Ar value Toggle ANSI colors display ( .Ar true or .Ar false ) .It Fl s Ar value Toggle symbols display ( .Ar true or .Ar false ) .It Fl k Ar key Specify OpenWeatherMap API key .It Fl w Ar value Toggle wind data display ( .Ar true or .Ar false ) .It Fl h Ar value Toggle humidity data display ( .Ar true or .Ar false ) .It Fl p Ar value Toggle pressure data display ( .Ar true or .Ar false ) .It Fl d Ar value Toggle daylight data display ( .Ar true or .Ar false ) .It Fl v Display version .El .Sh EXAMPLES Display forecast using metric units for the next five days (showing symbols and daylight data) for Rzeszow, Poland: .Pp ansiweather -l Rzeszow,PL -u metric -s true -f 5 -d true .Sh AUTHORS .Nm was written by .An Frederic Cambus . ansiweather-1.11/ansiweather.plugin.zsh000077500000000000000000000000421312255353600203070ustar00rootroot00000000000000export PATH=${PATH}:$(dirname $0) ansiweather-1.11/ansiweatherrc.example000066400000000000000000000015661312255353600201770ustar00rootroot00000000000000# .ansiweatherrc example showing all available options api_key:85a4e3c55b73909f42c6a23ec35b7147 fetch_cmd:curl -sf location:Rzeszow,PL units:metric forecast:0 ansi:true symbols:false show_wind:true show_humidity:true show_pressure:true show_daylight:false dateformat:%a %b %d timeformat:%b %d %r # Text and Colors background:\033[44m text:\033[36;1m data:\033[33;1m delimiter:\033[35m=> dashes:\033[34m- forecast_text:forecast greeting_text:Weather in humidity_text:Humidity pressure_text:Pressure sunrise_text:Sunrise sunset_text:Sunset wind_directions:N NNE NE ENE E ESE SE SSE S SSW SW WSW W WNW NW NNW wind_text:Wind # Icons sun:\033[33;1m\xe2\x98\x80 moon:\033[36m\xe2\x98\xbd clouds:\033[37;1m\xe2\x98\x81 rain:\033[37;1m\xe2\x98\x94 fog:\033[37;1m\xe2\x96\x92 mist:\033[34m\xe2\x96\x91 haze:\033[33m\xe2\x96\x91 snow:\033[37;1m\xe2\x9d\x84 thunderstorm:\033[33;1m\xe2\x9a\xa1 ansiweather-1.11/screenshot/000077500000000000000000000000001312255353600161305ustar00rootroot00000000000000ansiweather-1.11/screenshot/ansiweather.png000066400000000000000000000220321312255353600211470ustar00rootroot00000000000000PNG  IHDR*LbKGD pHYs  tIME ;-Si IDATxy\TهUAQ qODcҸ'i}5MRk6M&5K߾MMLTLb6{D+ 0lD5|?~wsysKM<9`0 ` `0 3 `01< p U=, {X5Hm&&}ŀ{ʪ۳*jfo$=]}"qp0缴:~;nP<ѓj_̬OyBVy1c 9*ĸU:ّe}TF3׍K(O1`tX+M#?o7[I<(Ϳ/lH%7Q-,1* U?"AcQ?Qyp4鱓?6n`2 lr'UߥbWf3WCf__0^_WRJ, |wQJH壛CB)}*;RxꅼyMzu|BlW}}AąLT;zSٸd_/M-z]o8*RyY=2MIu]uUID{i]ޙ^c1=/#IoKod ӿYl=¤4}^E)5+9y[%_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