You are not logged in.

#1381 2016-11-11 21:57:07

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,011

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

TeoBigusGeekus wrote:

A few from bears, a deer and either a giant dog, or a wolf.

If the moon was full that was me.  smile

Hmmmmmmmmmmmmmmm ... ${if_match ... will work ...}

]:D  ]:D  ]:D


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#1382 2016-11-11 22:03:36

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

${if_match any_more_scary_animals... will not work ...}


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1383 2016-11-11 22:19:13

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,011

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

lol  lol  lol  lol  lol  lol

You'll be fine ... Just keep yelling, "Hey Yogi, the Park Ranger wants you! Something about a missing picnic basket."  He won't dare show.


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#1384 2016-11-13 14:29:30

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,011

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

How can one tell it's a 'slow period' with nothing to do ....
PJWcgpBQ.jpg
I didn't bother with an ${if_match} I simply created a new new moon image and copied the wolf over it.  smile

Hmmmmmmmmmm with a bit of conky magic ... Blue Moon  smile  It would just need a blue filter.  smile


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#1385 2016-11-13 14:49:39

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

lol
Nice one S11, though a bit unsettling...


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1386 2016-11-13 16:58:52

unklar
Back to the roots 1.9
From: #! BL
Registered: 2015-10-31
Posts: 2,647

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Whether the wolf is unsettling ...  big_smile

Then we still have a mistake in the northern hemisphere.
Here the full moon is displayed for the 15-11-16   hmm
http://www.moongiant.com/phase/today/
wolf1fehler.th.jpg
script

#!/bin/bash

#function: moonrise_set
moonrise_set () {
    case "$1" in
         "FirstQuarter")
			echo "Noon/Midnight"
			cp $HOME/4_Moon/riseicons/rise_FirstQuarter.jpg $HOME/4_Moon/rise.jpg
         ;;
         "FullMoon")
			echo "6PM/6AM"
			cp $HOME/4_Moon/riseicons/rise_FullMoon.jpg $HOME/4_Moon/rise.jpg
		 ;;	
		 "LastQuarter")
			echo "Midnight/Noon"
			cp $HOME/4_Moon/riseicons/rise_LastQuarter.jpg $HOME/4_Moon/rise.jpg
		 ;;	
		 "NewMoon")
			echo "6AM/6PM"
			cp $HOME/4_Moon/riseicons/rise_NewMoon.jpg $HOME/4_Moon/rise.jpg
		 ;;
		 "WaningCrescent")
			echo "3AM/3PM"
			cp $HOME/4_Moon/riseicons/rise_WaningCrescent.jpg $HOME/4_Moon/rise.jpg
		 ;;
		 "WaningGibbous")
			echo "9PM/9AM"
			cp $HOME/4_Moon/riseicons/rise_WaningGibbous.jpg $HOME/4_Moon/rise.jpg
		 ;;
		 "WaxingCrescent")
			echo "9AM/9PM"
			cp $HOME/4_Moon/riseicons/rise_WaxingCrescent.jpg $HOME/4_Moon/rise.jpg
		 ;;
		 "WaxingGibbous")
			echo "3PM/3AM"
			cp $HOME/4_Moon/riseicons/rise_WaxingGibbous.jpg $HOME/4_Moon/rise.jpg
		 ;;
		 *)
			echo "Unavailable"
		 esac
} 

kill -STOP $(pidof conky)

#put your hemisphere here: north or south
hemisphere=north

wget -O $HOME/4_Moon/raw "http://www.moongiant.com/phase/today"
rm $HOME/4_Moon/*.png $HOME/4_Moon/*.jpg

sed -i -e '/^ *$/d' -e 's/^ *//g' $HOME/4_Moon/raw
sed -i '/var jArray=\|"todayMoonContainer"\|"moonNotToday"/!d' $HOME/4_Moon/raw
sed -i -e '/var jArray/s/","/\n/g' -e 's/<span>\|<b>\|<\\\/span>\|<\\\/b>\|\\n//g' /$HOME/4_Moon/raw
sed -i -e '/var jArray/d' -e 's/^.*\:\[\"//g' /$HOME/4_Moon/raw
sed -i -e 's/"\]};//g' -e 's/^.*today_phase\///g' -e 's/\.jpg.*$//g' /$HOME/4_Moon/raw
sed -i -e 's/^small\///g' -e 's/\.png.*$//g' /$HOME/4_Moon/raw
sed -i -e 's/Illumination: \|Sun Angle: \|Sun Distance: \|Moon Distance: \|Moon Age: \|Moon Angle: //g' -e '43d' /$HOME/4_Moon/raw
#September 30-October 1 fix
for (( i=11; i<=35; i+=8 ))
	do
		if [[ $(sed -n ${i}p /$HOME/4_Moon/raw) == "September 30" ]]; then
			line=$((i+7))
			sed -i "${line}s/^.*$/Waning Crescent/" /$HOME/4_Moon/raw
		fi
		if [[ $(sed -n ${i}p /$HOME/4_Moon/raw) == "October 1" ]]; then
			line=$((i+7))
			sed -i "${line}s/^.*$/New Moon/" /$HOME/4_Moon/raw
		fi
	done
today_phase=$(sed -n 8p /$HOME/4_Moon/raw| awk -F "," '{print $2}'| sed 's/ //')
if [[ $today_phase == "September 30" ]]; then
			sed -i '7s/^.*$/Waning Crescent/' /$HOME/4_Moon/raw
			sed -i '10s/^.*$/Phase: Waning Crescent/' /$HOME/4_Moon/raw
fi
if [[ $today_phase == "October 1" ]]; then
			sed -i '7s/^.*$/New Moon/' /$HOME/4_Moon/raw
			sed -i '10s/^.*$/Phase: New Moon/' /$HOME/4_Moon/raw
fi

phase=$(sed -n 7p $HOME/4_Moon/raw|sed 's/ //')
mrise_mset=$(moonrise_set $phase)
sed -i 7a$(moonrise_set $phase) /$HOME/4_Moon/raw

#Day before Yesterday
img_in=$(sed -n 44p $HOME/4_Moon/raw)
cp $HOME/4_Moon/moongiant_icons_$hemisphere/$img_in.png $HOME/4_Moon/-2.png

#Yesterday
img_in=$(sed -n 45p $HOME/4_Moon/raw)
cp $HOME/4_Moon/moongiant_icons_$hemisphere/$img_in.png $HOME/4_Moon/-1.png

#Today
img_in=$(sed -n 46p $HOME/4_Moon/raw)
cp $HOME/4_Moon/moongiant_icons_$hemisphere/$img_in.png $HOME/4_Moon/0.png

#Tomorrow
img_in=$(sed -n 47p $HOME/4_Moon/raw)
cp $HOME/4_Moon/moongiant_icons_$hemisphere/$img_in.png $HOME/4_Moon/1.png

#Day after Tomorrow
img_in=$(sed -n 48p $HOME/4_Moon/raw)
cp $HOME/4_Moon/moongiant_icons_$hemisphere/$img_in.png $HOME/4_Moon/2.png

date +%T > $HOME/4_Moon/aktualisiert
kill -CONT $(pidof conky) 

Online

#1387 2016-11-13 17:17:42

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

No, I get correct moon phases.
Maybe you happened to check when the site was changing them?


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1388 2016-11-13 17:30:23

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,011

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

I get Full Moon tomorrow as well.

Hey Teo  - Maybe a Happy Face full moon.
u2AB9zmb.jpg
Looks like a kid that ate too much sweets!  big_smile


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#1389 2016-11-13 18:54:31

unklar
Back to the roots 1.9
From: #! BL
Registered: 2015-10-31
Posts: 2,647

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Ok Teo, you're right.  wink
wolf2fehler.th.jpg

Probably there is then a time synchronization error - @Sector11?

.conkyrc_4_Moon_S11_V1

...


TEXT
${font Fantasque Sans Mono:bold:size=12}${color1}Mond-Phasen ${membar 1}${color}${texeci 500 bash $HOME/4_Moon/moon_MoonGiant}
${color1}${execpi 600 sed -n '1p' $HOME/4_Moon/aktualisiert}${alignc}${color3}${execi 3600 echo `date --date="0 day" | awk '{print $1" "$2" "$3" "$6}'`}${color}${font}
${image $HOME/4_Moon/-2.png -p 10,65 -s 60x60}
${image $HOME/4_Moon/-1.png -p 80,65 -s 60x60}
${image $HOME/4_Moon/0.png -p 157,35 -s 90x90}
${image $HOME/4_Moon/1.png -p 265,65 -s 60x60}
${image $HOME/4_Moon/2.png -p 340,65 -s 60x60}


${alignc}${execpi 600 sed -n '7p' $HOME/4_Moon/raw | awk '{print $1}'}
${alignc}${execpi 600 sed -n '7p' $HOME/4_Moon/raw | awk '{print $2}'}
${alignc}${execpi 600 sed -n '1p' $HOME/4_Moon/raw}
${voffset -42}${color1}${goto 15}${color1}${execi 3600 echo `date --date="-2 day" | awk '{print $2" "$3}'`}\
${goto 87}${execi 3600 echo `date --date="-1 day" | awk '{print $2" "$3}'`}\
${goto 347}${execi 3600 echo `date --date="+2 day" | awk '{print $2" "$3}'`}\
${goto 272}${execi 3600 echo `date --date="+1 day" | awk '{print $2" "$3}'`}${color}
${goto 15}${execpi 600 sed -n '19p' $HOME/4_Moon/raw | awk '{print $1}'}\
${goto 87}${execpi 600 sed -n '27p' $HOME/4_Moon/raw | awk '{print $1}'}\
${goto 272}${execpi 600 sed -n '35p' $HOME/4_Moon/raw | awk '{print $1}'}\
${goto 347}${execpi 600 sed -n '43p' $HOME/4_Moon/raw | awk '{print $1}'}
${goto 15}${execpi 600 sed -n '19p' $HOME/4_Moon/raw | awk '{print $2}'}\
${goto 87}${execpi 600 sed -n '27p' $HOME/4_Moon/raw | awk '{print $2}'}\
${goto 272}${execpi 600 sed -n '35p' $HOME/4_Moon/raw | awk '{print $2}'}\
${goto 347}${execpi 600 sed -n '43p' $HOME/4_Moon/raw | awk '{print $2}'}
${goto 15}${execpi 600 sed -n '13p' $HOME/4_Moon/raw}\
${goto 87}${execpi 600 sed -n '21p' $HOME/4_Moon/raw}\
${goto 272}${execpi 600 sed -n '29p' $HOME/4_Moon/raw}\
${goto 347}${execpi 600 sed -n '37p' $HOME/4_Moon/raw}

${alignc}${color3}Details für ${execi 3600 echo `date --date="0 day" | awk '{print $1" "$2" "$3" "$6}'`}${color}

Ausleuchtung: ${execpi 600 sed -n '1p' $HOME/4_Moon/raw}${goto 250}Mondalter: ${execpi 600 sed -n '5p' $HOME/4_Moon/raw}
Sonnenwinkel: ${execpi 600 sed -n '2p' $HOME/4_Moon/raw}${goto 250}Mondwinkel: ${execpi 600 sed -n '6p' $HOME/4_Moon/raw}
Entfernung: ${execpi 600 sed -n '3p' $HOME/4_Moon/raw}${goto 250}Entfernung: ${execpi 600 sed -n '4p' $HOME/4_Moon/raw}

${alignc}${color1}Durchschnittliche Mondauf -und Untergangszeiten${color}\
${image $HOME/4_Moon/rise.jpg -p 0,300 -s 400x99}\
${image $HOME/4_Moon/0.png -p 45,350 -s 30x30}\
${image $HOME/4_Moon/0.png -p 325,350 -s 30x30}\
${image $HOME/4_Moon/0.png -p 185,300 -s 30x30}

Did you see one?   O:)

Online

#1390 2016-11-13 19:27:08

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,011

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

${texeci 500 bash $HOME/4_Moon/moon_MoonGiant}

That is OLD!!!!!

But looks familiar in my test.conky  big_smile
eabUAg7Q.jpg


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#1391 2016-11-13 21:09:23

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Sector11 wrote:

Looks like a kid that ate too much sweets!  big_smile

...and got acne, right, now I get it...

Last edited by TeoBigusGeekus (2016-11-13 21:42:19)


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1392 2016-11-13 21:44:21

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,011

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Worst case ever!  Sure doesn't look like green cheese lol  lol  lol


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#1393 2016-11-15 18:42:51

mihaicociuba
New Member
Registered: 2016-10-26
Posts: 4

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

when my internet connection is down or when I wake up the laptop the images aren't showing but the text is.
Is this the expected behavior?

Offline

#1394 2016-11-15 19:40:44

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

mihaicociuba wrote:

when my internet connection is down or when I wake up the laptop the images aren't showing but the text is.
Is this the expected behavior?

Yep, the script deletes all images before downloading new ones.
This way, you'll know when the script hasn't really been updated.


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1395 2016-11-16 06:02:36

mihaicociuba
New Member
Registered: 2016-10-26
Posts: 4

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

I understand.
If I modify the update interval of the script,  for example 4 times a day,  then the images will remain in the conky or it depends on the Internet connection?

Offline

#1396 2016-11-16 06:06:56

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

mihaicociuba wrote:

I understand.
If I modify the update interval of the script,  for example 4 times a day,  then the images will remain in the conky or it depends on the Internet connection?

The script has no way of knowing your connection is down unless it tries to update.
When the latter happens, it deletes the previous images and tries to create new ones; if you have no connection, it'll fail.

So, yeah, if you change the update interval you'll be fine.


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1397 2016-11-18 14:30:16

unklar
Back to the roots 1.9
From: #! BL
Registered: 2015-10-31
Posts: 2,647

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Sector11 wrote:
${texeci 500 bash $HOME/4_Moon/moon_MoonGiant}

That is OLD!!!!!

It is actually so that the command

texeci

leads to a delay in the correct representation. Here concretely in the 4_Moon Conky are the 15 minutes and I have actually the representation of the switch off the computer.

When the command

execi

the representation is true in 99% of the cases. I have tested this over a longer period of time, also with other weather conkys.

^ Sector11
in the "old spirit" again learned something.  big_smile  You are right the "El Conkystador"!

Online

#1398 2016-11-18 23:16:13

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,011

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

^ actually, I was wrong, I thought "moon_MoonGiant" was old - I renamed mine to just "moon" and now I can't remember when I did that.

Ahhh ... my forgetter is getting even better than I thought!  big_smile


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#1399 2016-11-18 23:49:16

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,011

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

My Wife, Sector12, just pointed out and error in my weather conky ... and I never noticed, but it has been there since it's creation and first published here and there there was another hint published here.  I'm  :8 :8  that "I" have never noticed it.

But to think it's here "twice" ... and no one else saw it either ... I can take a little comfort in that.  smile

So here's the conky - do you see it:
I6sXMum9.jpg
On the right .... bottom line .... yikes

{sigh} Of course it is fixed now and also in the code "first published" link above.

An OOPS! corrected!

Way to go Sector12!!!


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#1400 2016-11-19 15:15:20

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Hey, if you haven't made any mistakes, you haven't actually tried wink


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

Board footer

Powered by FluxBB