pmwf (Poor Man's Weather Forecast) - current conditions + 3 days forecast

VastOne

Added all data as described in How To thread and all is working perfectly now

Thanks hakerdefo!!!
VSIDO      VSIDO Change Blog    

    I dev VSIDO

PackRat

I can confirm that this script works with Arch linux



all the dependencies were available in the Extras so no messing with the AUR (hurray!)
I am tired of talk that comes to nothing.
-- Chief Joseph

...the sun, the darkness, the winds are all listening to what we have to say.
-- Geronimo

PackRat

Your new version isn't working for me - not grabbing the weather data.

Since you're back to actively developing this, I'll make a request  ;D

My script gives:

Current Weather
Forecast for next Day
Forecast for Day 2
Forecast Day 3
Forecast Day 4

It would be more useful (to me anyway) if it was:

Current Weather
Forecast for Current Day
Forecast Next Day
Forecast for Day 2
Foarecast for Day 3

I tried to edit myself once and borked the script really bad.
I am tired of talk that comes to nothing.
-- Chief Joseph

...the sun, the darkness, the winds are all listening to what we have to say.
-- Geronimo

VastOne

VSIDO      VSIDO Change Blog    

    I dev VSIDO

hakerdefo

Will add the forecast for current day asap!
The updated script is not working for you?
Did you edit the script and add the values to the following variables,


local_latitude=
local_longitude=
local_unit=
api_key=


Cheers!!!
You Can't Always Git What You Want

PackRat

Yes, I just plugged them in from my original script.

That api_key value should still work shouldn't it? Looks like the main change was switching to wget from curl.

ran it in a terminal and get this error:

conky: window type - desktop
conky: drawing to created window (0x1600001)
conky: drawing to double buffer
conky: forked to background, pid is 1369

date: invalid date '@'
date: invalid date '@'
date: invalid date '@'
awk: cmd. line:1: BEGIN {print  * 3.6}
awk: cmd. line:1:               ^ syntax error
awk: cmd. line:1: BEGIN {print  * 3.6}
awk: cmd. line:1:               ^ syntax error
awk: cmd. line:1: BEGIN {print  * 3.6}
awk: cmd. line:1:               ^ syntax error
awk: cmd. line:1: BEGIN {print  * 3.6}
awk: cmd. line:1:               ^ syntax error


I am tired of talk that comes to nothing.
-- Chief Joseph

...the sun, the darkness, the winds are all listening to what we have to say.
-- Geronimo

PackRat

Fixed a couple typos on my part -

in terminal still failes with:

date: invalid date '@'
date: invalid date '@'
date: invalid date '@'
I am tired of talk that comes to nothing.
-- Chief Joseph

...the sun, the darkness, the winds are all listening to what we have to say.
-- Geronimo

hakerdefo

This is a locale issue. You can easily fix it by adding the following line at the top of the pmwf script,


export LC_TIME=C


Cheers!!!
You Can't Always Git What You Want

PackRat

I am tired of talk that comes to nothing.
-- Chief Joseph

...the sun, the darkness, the winds are all listening to what we have to say.
-- Geronimo

hakerdefo

Then try and add the following line right at the top (Right after the interpreter line),


export LC_ALL=C


The beginning of the pmwf will look something like this after the changes,


#!/usr/bin/env bash
###################
export LC_TIME=C
export LC_ALL=C
local_latitude=
local_longitude=
local_unit=
api_key=
local_rm=$(which rm)


Cheers!!!
You Can't Always Git What You Want

PackRat

^ thanks.

Appears to be a issue with the computer. Just did a clean install the other day.

The new script works fine on my other computers - Void and VSIDO - so it's not a Void v. Debian under the hood issue.

Edit - did areconfiguration of locale, script works as is now
I am tired of talk that comes to nothing.
-- Chief Joseph

...the sun, the darkness, the winds are all listening to what we have to say.
-- Geronimo

jedi

Just so happened to have a brand new VSIDO uEFI build going (and loving it!) and have completed all the necessary steps to make it my official 'goto' and as usual, your script works beautifully!  Suddenly minus one conky on the desktop now.  hmmm.  Let's see what happens.  I'm pretty fond of conky...  (not that this can't be utilized fully inside a conky file,  ::) and probably somebody here has already done it!!!)

Beautiful scripting as usual hakerdefoe!  8)

EDIT: Scrot or it didn't happen!

Forum Netiquette

"No matter how smart you are you can never convince someone stupid that they are stupid."  Anonymous