You are not logged in.

#3951 2021-01-23 23:51:35

TeoBigusGeekus
BL DieHard
From: /Greece/Kastoria
Registered: 2015-10-04
Posts: 1,466

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

Oh yeah, I've forgotten about moongiant.
I'm afraid it's gonna have to wait a few days, this week is particular busy for me, sorry.


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

#3952 2021-01-30 23:33:06

TeoBigusGeekus
BL DieHard
From: /Greece/Kastoria
Registered: 2015-10-04
Posts: 1,466

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

Preliminary draft for the Moon Giant script:

#!/usr/bin/env bash

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

#########################################################################################
# Put the command that launches the conky configuration file that uses this script here #
#########################################################################################
weather_conky_launch_command="conky -b"

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

wget -q -O $HOME/Moongiant_conky_script/raw "https://www.moongiant.com/phase/today"
rm $HOME/Moongiant_conky_script/*.png $HOME/Moongiant_conky_script/*.jpg

sed -i '/<!-- divs for marking today -->/,/<div id="timeConvertContainer">/!d' $HOME/Moongiant_conky_script/raw
sed -i '/Phase Details for\|Phase: \|Illumination: \|Moon Age: \|Moon Angle: \|Moon Distance: \|Sun Angle: \|Sun Distance: \|src="\/images\/today_phase\/\|<\/b><br>/!d' $HOME/Moongiant_conky_script/raw
sed -i -e 's/^.*moon_day_//g' -e 's/^ *<b>//g' -e's/<\/b><br>/\n/g' -e 's/^.*Phase: <span>//g' -e 's/^.* Illumination: <span>//g' -e 's/^.*Moon Age: <span>//g' -e 's/^.*Moon Angle: <span>//g' -e 's/^.*Moon Distance: <span>//g' -e 's/^.*Sun Angle: <span>//g' -e 's/^.*Sun Distance: <span>//g' -e '/<div class=\| Full Moon Calendar\|<h2 class=/d' -e 's/\.png.*$//g' -e 's/\.jpg.*$//g' -e 's/<br>$//g' -e 's/<br>/\n/g' -e 's/Illumination: <span>//' -e 's/<\/span>$//g' -e 's/<\/span>//g' $HOME/Moongiant_conky_script/raw

phase=$(sed -n 21p $HOME/Moongiant_conky_script/raw|sed 's/ //')
mrise_mset=$(moonrise_set $phase)
sed -i 21a$(moonrise_set $phase) $HOME/Moongiant_conky_script/raw

#Day before Yesterday
img_in=$(sed -n 1p $HOME/Moongiant_conky_script/raw)
cp $HOME/Moongiant_conky_script/moongiant_icons_$hemisphere/moon_day_$img_in.png $HOME/Moongiant_conky_script/-2.png

#Yesterday
img_in=$(sed -n 5p $HOME/Moongiant_conky_script/raw)
cp $HOME/Moongiant_conky_script/moongiant_icons_$hemisphere/moon_day_$img_in.png $HOME/Moongiant_conky_script/-1.png

#Today
img_in=$(sed -n 9p $HOME/Moongiant_conky_script/raw)
cp $HOME/Moongiant_conky_script/moongiant_icons_$hemisphere/moon_day_$img_in.png $HOME/Moongiant_conky_script/0.png

#Tomorrow
img_in=$(sed -n 13p $HOME/Moongiant_conky_script/raw)
cp $HOME/Moongiant_conky_script/moongiant_icons_$hemisphere/moon_day_$img_in.png $HOME/Moongiant_conky_script/1.png

#Day after Tomorrow
img_in=$(sed -n 17p $HOME/Moongiant_conky_script/raw)
cp $HOME/Moongiant_conky_script/moongiant_icons_$hemisphere/moon_day_$img_in.png $HOME/Moongiant_conky_script/2.png

#Resume weather conky
pkill -CONT -xf "$weather_conky_launch_command"

The new layout of the page doesn't have all the details (moon/sun age, angle, distance) other than today. I must download four additional pages in order to have this info - I chose not to do because it would seriously impair the script's overall speed.
So the second conkyrc (the one with the extensive moon details) will stop working - I don't think anyone was using it anyway.
Other than that, major, MAJOR cleanup of the code and the output has changed, so I much change the remaining conkyrc as well.
Thanks all for your patience.


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

#3953 2021-01-31 18:59:43

unklar
Member
Registered: 2015-10-31
Posts: 1,364

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

Teo, thank you  smile

the script is ok according to m.M.
No errors are displayed. Logically, the outputs do not match the old configuration files. wink
But this is not difficult to fix.

I see this raw

WanG_95
January 29
Waning Gibbous
99%
WanG_95
January 30
Waning Gibbous
97%
WanG_90
January 31
Waning Gibbous
91%
WanG_80
February 1
Waning Gibbous
84%
WanG_75
February 2
Waning Gibbous
75%
Waning Gibbous
9PM/9AM
91%
17.58 days
0.54
371,728.88 km
0.54
147,406,887.63 km

kiYxk4Qt.png

Offline

#3954 2021-02-01 11:39:37

unklar
Member
Registered: 2015-10-31
Posts: 1,364

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

Teo, if you agree, you could publish the configuration file like this.
Please, but check for errors before  wink
One catches my eye: Could it be that there is an error in the script between sun angle and moon angle?
zataIiWt.png

.conkyrc_Moon_S11_V1

conky.config = {
--##  Begin Window Settings  ##################################################
	own_window = true,
	own_window_type = 'normal',
	own_window_transparent = true,
	own_window_hints = 'undecorated,below,skip_taskbar,skip_pager',
	own_window_colour = '#000000',
	own_window_class = 'Conky',
	own_window_title = '4_Moon Teo Style',

--##		minimum_size 450 00  # w|h
--##		maximum_width 450
	minimum_width = 400, minimum_height = 500,
	maximum_width = 400,

	gap_x = 20,-- l|r
	gap_y = 50,-- u|d

	alignment = 'top_right',
--###################################################  End Window Settings  ###
--##  Font Settings  ##########################################################
-- Use Xft (anti-aliased font and stuff)
	use_xft = true,
	font = 'Fantasque Sans Mono:bold:size=10',

-- Alpha of Xft font. Must be a value at or between 1 and 0 ###
	xftalpha = 1.0,

-- Force UTF8? requires XFT ###
	override_utf8_locale = true,

	uppercase = false,
--#####################################################  End Font Settings  ###
--##  Color Settings  #########################################################
	draw_shades = true,
	default_shade_color = '#000000',
	draw_outline = false,
	default_outline_color = '#000000',

	default_color = '#DCDCDC',--Gainsboro
	color0 = '#8FBC8F',--DarkSeaGreen
	color1 = '#778899',--LightSlateGray
	color2 = '#F5F5DC',--Beige
	color3 = '#87CEFA',--LightSkyBlue
	color4 = '#48D1CC',--MediumTurquoise
	color5 = '#FFDEAD',--NavajoWhite
	color6 = '#00BFFF',--DeepSkyBlue
	color7 = '#B0E0E6',--PowderBlue
	color8 = '#FFD700',--Gold
	color9 = '#CD5C5C',--IndianRed
--####################################################  End Color Settings  ###
--##  Borders Section  ########################################################
	draw_borders = false,
-- Stippled borders?
	stippled_borders = 5,
-- border margins
	border_inner_margin = 5,
	border_outer_margin = 0,
-- border width
	border_width = 2,
-- graph borders
	draw_graph_borders = true,--no
--default_graph_size 15 40
--####################################################  End Borders Secton  ###
--##  Miscellaneous Section  ##################################################
-- Boolean value, if true, Conky will be forked to background when started.
	background = true,

-- Adds spaces around certain objects to stop them from moving other things
-- around, this only helps if you are using a mono font
-- Options: right, left or none
	use_spacer = 'none',

-- Default and Minimum size is 256 - needs more for single commands that
-- "call" a lot of text IE: bash scripts
--text_buffer_size 6144

-- Subtract (file slystem) buffers from used memory?
	no_buffers = true,

-- change GiB to G and MiB to M
	short_units = true,

-- Like it says, ot pads the decimals on % values
-- doesn't seem to work since v1.7.1
	pad_percents = 2,

-- Imlib2 image cache size, in bytes. Default 4MiB Increase this value if you use
-- $image lots. Set to 0 to disable th0e image cache.
	imlib_cache_size = 0,

-- Use the Xdbe extension? (eliminates flicker)
-- It is highly recommended to use own window with this one
-- so double buffer won't be so big.
	double_buffer = true,
--#############################################  End Miscellaneous Section  ###
	update_interval = 1,


};

conky.text = [[
${font Fantasque Sans Mono:bold:size=12}${color5}Moon Phases ${membar 0}${color}${texeci 500 bash $HOME/Moongiant_conky_script/moongiant}
${alignc}${color5}${execi 3600 echo `date --date="0 day" | awk '{print $1" "$3" "$2" "$6}'`}${color}${font}
${image $HOME/Moongiant_conky_script/-2.png -p 10,65 -s 60x60}
${image $HOME/Moongiant_conky_script/-1.png -p 80,65 -s 60x60}
${image $HOME/Moongiant_conky_script/0.png -p 157,35 -s 90x90}
${image $HOME/Moongiant_conky_script/1.png -p 265,65 -s 60x60}
${image $HOME/Moongiant_conky_script/2.png -p 340,65 -s 60x60}


${alignc}${execpi 600 sed -n '11p' $HOME/Moongiant_conky_script/raw | awk '{print $1}'}
${alignc}${execpi 600 sed -n '11p' $HOME/Moongiant_conky_script/raw | awk '{print $2}'}
${alignc}${execpi 600 sed -n '12p' $HOME/Moongiant_conky_script/raw}
${voffset -42}${color5}${goto 15}${color5}${execi 3600 echo `date --date="-2 day" | awk '{print $3" "$2}'`}\
${goto 87}${execi 3600 echo `date --date="-1 day" | awk '{print $3" "$2}'`}\
${goto 347}${execi 3600 echo `date --date="+2 day" | awk '{print $3" "$2}'`}\
${goto 272}${execi 3600 echo `date --date="+1 day" | awk '{print $3" "$2}'`}${color}
${goto 15}${execpi 600 sed -n '3p' $HOME/Moongiant_conky_script/raw | awk '{print $1}'}\
${goto 87}${execpi 600 sed -n '7p' $HOME/Moongiant_conky_script/raw | awk '{print $1}'}\
${goto 272}${execpi 600 sed -n '15p' $HOME/Moongiant_conky_script/raw | awk '{print $1}'}\
${goto 347}${execpi 600 sed -n '19p' $HOME/Moongiant_conky_script/raw | awk '{print $1}'}
${goto 15}${execpi 600 sed -n '3p' $HOME/Moongiant_conky_script/raw | awk '{print $2}'}\
${goto 87}${execpi 600 sed -n '7p' $HOME/Moongiant_conky_script/raw | awk '{print $2}'}\
${goto 272}${execpi 600 sed -n '15p' $HOME/Moongiant_conky_script/raw | awk '{print $2}'}\
${goto 347}${execpi 600 sed -n '19p' $HOME/Moongiant_conky_script/raw | awk '{print $2}'}
${goto 15}${execpi 600 sed -n '4p' $HOME/Moongiant_conky_script/raw}\
${goto 87}${execpi 600 sed -n '8p' $HOME/Moongiant_conky_script/raw}\
${goto 272}${execpi 600 sed -n '16p' $HOME/Moongiant_conky_script/raw}\
${goto 347}${execpi 600 sed -n '20p' $HOME/Moongiant_conky_script/raw}

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

${font Fantasque Sans Mono:bold:size=9}Illumination: ${execpi 600 sed -n '4p' $HOME/Moongiant_conky_script/raw}${goto 230}Moon Age: ${execpi 600 sed -n '24p' $HOME/Moongiant_conky_script/raw}
Sun Angle: ${execpi 600 sed -n '25p' $HOME/Moongiant_conky_script/raw}${goto 230}Moon Angle: ${execpi 600 sed -n '27p' $HOME/Moongiant_conky_script/raw}
Sun Distance: ${execpi 600 sed -n '28p' $HOME/Moongiant_conky_script/raw}${goto 230}Moon Distance: ${execpi 600 sed -n '26p' $HOME/Moongiant_conky_script/raw}

${alignc}${color5}Average moonrise and moonset times${color}\
${image $HOME/Moongiant_conky_script/rise.jpg -p 0,300 -s 400x99}\
${image $HOME/Moongiant_conky_script/0.png -p 45,350 -s 30x30}\
${image $HOME/Moongiant_conky_script/0.png -p 325,350 -s 30x30}\
${image $HOME/Moongiant_conky_script/0.png -p 185,300 -s 30x30}
]];

Last edited by unklar (2021-02-01 11:45:41)

Offline

#3955 2021-02-01 13:52:04

unklar
Member
Registered: 2015-10-31
Posts: 1,364

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

8f9OChVt.png

.small_moon.conky10  big_smile

-- pkill -xf "conky -c /path/to/conkyrc" &
-- idea from "El Conkystador" @Sector11
-- 2020-09-26; 2021-02-01 conkyV1.10 @unklar
conky.config = {
--##  Begin Window Settings  ##################################################
	own_window = true,
	own_window_type = 'normal',
	own_window_transparent = true,
	own_window_hints = 'undecorated,below,skip_taskbar,skip_pager',
	own_window_colour = '000000',
	own_window_class = 'Conky',
--own_window_argb_visual = true,
--own_window_argb_value 255
--own_window_title 4_Moon Teo Style

	minimum_width = 480, minimum_height = 150,
--maximum_width = 480,

	gap_x = 230, -- l|r
	gap_y = 50, -- u|d

	alignment = 'bottom_right',
--###################################################  End Window Settings  ###
--##  Font Settings  ##########################################################
-- Use Xft (anti-aliased font and stuff)
	use_xft = true,
--xftfont Fantasque Sans Mono:bold:size=9
	font = 'monofur:size=8',

-- Alpha of Xft font. Must be a value at or between 1 and 0 ###
	xftalpha = 1.0,

-- Force UTF8? requires XFT ###
	override_utf8_locale = true,

	uppercase = false,
--#####################################################  End Font Settings  ###
--##  Color Settings  #########################################################
	draw_shades = true,
	default_shade_color = '000000',
	draw_outline = false,
	default_outline_color = '000000',

	default_color = 'DCDCDC',--Gainsboro
	color0 = '8FBC8F',--DarkSeaGreen
	color1 = '778899',--LightSlateGray
	color2 = 'F5F5DC',--Beige
	color3 = '87CEFA',--LightSkyBlue
	color4 = '48D1CC',--MediumTurquoise
	color5 = 'FFDEAD',--NavajoWhite
	color6 = '00BFFF',--DeepSkyBlue
	color7 = 'B0E0E6',--PowderBlue
	color8 = 'FFD700',--Gold
	color9 = 'CD5C5C',--IndianRed
--####################################################  End Color Settings  ###
--##  Borders Section  ########################################################
	draw_borders = false,
-- Stippled borders?
	stippled_borders = 5,
-- border margins
	border_inner_margin = 5,
	border_outer_margin = 0,
-- border width
	border_width = 2,
-- graph borders
	draw_graph_borders = true,
--default_graph_size 15 40
--####################################################  End Borders Secton  ###
--##  Miscellaneous Section  ##################################################
-- Boolean value, if true, Conky will be forked to background when started.
	background = true,

-- Adds spaces around certain objects to stop them from moving other things
-- around, this only helps if you are using a mono font
-- Options: right, left or none
	use_spacer = 'none',

-- Default and Minimum size is 256 - needs more for single commands that
-- "call" a lot of text IE: bash scripts
--text_buffer_size 6144

-- Subtract (file slystem) buffers from used memory?
	no_buffers = true,

-- change GiB to G and MiB to M
	short_units = true,

-- Like it says, ot pads the decimals on % values
-- doesn't seem to work since v1.7.1
	pad_percents = 2,

-- Imlib2 image cache size, in bytes. Default 4MiB Increase this value if you use
-- $image lots. Set to 0 to disable th0e image cache.
	imlib_cache_size = 0,

-- Use the Xdbe extension? (eliminates flicker)
-- It is highly recommended to use own window with this one
-- so double buffer won't be so big.
	double_buffer = true,
--#############################################  End Miscellaneous Section  ###
	update_interval = 1,--2,
	
-- LUA --	
-- lua_load = '~/.conky/scripts/draw_bg.lua',
-- lua_draw_hook_pre = 'draw_bg 10 0 0 0 0 0x000000 0.55',


};

conky.text = [[
${texeci 500 $HOME/Moongiant_conky_script/moongiant}\
${image $HOME/Moongiant_conky_script/-2.png -p 13,20 -s 45x45}\
${image $HOME/Moongiant_conky_script/-1.png -p 13,90 -s 45x45}\
${image $HOME/Moongiant_conky_script/0.png -p 200,45 -s 80x80}\
${image $HOME/Moongiant_conky_script/1.png -p 420,20 -s 45x45}\
${image $HOME/Moongiant_conky_script/2.png -p 420,90 -s 45x45}\
${goto 13}${execi 3600 echo `date --date="-2 day" | awk '{print $1" "$2" "$3}'`}\
${goto 232}Today\
${goto 420}${execi 3600 echo `date --date="1 day" | awk '{print $1" "$2" "$3}'`}


${goto 110} Illumination:${goto 310}${execpi 600 sed -n '23p' $HOME/Moongiant_conky_script/raw}
${goto 110}    Sun Angle:${goto 310}${execpi 600 sed -n '25p' $HOME/Moongiant_conky_script/raw}°
${goto 110} Sun Distance:${goto 310}${execpi 600 sed -n '28p' $HOME/Moongiant_conky_script/raw} 
${goto 13}${execi 3600 echo `date --date="-1 day" | awk '{print $1" "$2" "$3}'`}\
${goto 110}Moon Distance:${goto 310}${execpi 600 sed -n '26p' $HOME/Moongiant_conky_script/raw} \
${goto 420}${execi 3600 echo `date --date="2 day" | awk '{print $1" "$2" "$3}'`}
${goto 110}     Moon Age:${goto 310}${execpi 600 sed -n '24p' $HOME/Moongiant_conky_script/raw}
${goto 110}   Moon Angle:${goto 310}${execpi 600 sed -n '27p' $HOME/Moongiant_conky_script/raw}°
${goto 110}        Phase:${goto 310}${execpi 600 sed -n '21p' $HOME/Moongiant_conky_script/raw}
${goto 110} Moonrise/Set:${goto 310}${execpi 600 sed -n '22p' $HOME/Moongiant_conky_script/raw}
]];

Last edited by unklar (2021-02-01 16:02:33)

Offline

#3956 2021-02-01 21:17:06

TeoBigusGeekus
BL DieHard
From: /Greece/Kastoria
Registered: 2015-10-04
Posts: 1,466

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

Nice work unklar, this will definitely be included in the final script, to replace the discontinued conkyrc.
What's wrong with sun and moon angle?


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

#3957 2021-02-02 09:20:13

unklar
Member
Registered: 2015-10-31
Posts: 1,364

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

TeoBigusGeekus wrote:

Nice work unklar, this will definitely be included in the final script, to replace the discontinued conkyrc.
What's wrong with sun and moon angle?

^I assumed yesterday that it cannot be true if sun and moon angles are equal (54°).
Today I have checked it on the web page. It is ok. wink
Sorry.

However, the raw values are not correct with the web page.  neutral

WanG_95
January 30
Waning Gibbous
97%
WanG_90
January 31
Waning Gibbous
91%
WanG_80
February 1
Waning Gibbous
84%
WanG_75
February 2
Waning Gibbous
75%
WanG_60
February 3
Waning Gibbous
64%
Waning Gibbous
9PM/9AM
84%
18.65 days
0.54
368,165.13 km
0.54
147,428,254.74 km

py4pHYRt.png
this is now

Edit:
Now everything is correct. big_smile A waiting time of 15 minutes was not enough. After ~30 minutes the correct values are displayed. Thereby it says in the conkyrc

...
${texeci 500 bash $HOME/Moongiant_conky_script/moongiant}
...
Illumination:${goto 310}${execpi 600 sed -n '23p' $HOME/Moongiant_conky_script/raw}
...

Last edited by unklar (2021-02-02 10:05:10)

Offline

#3958 2021-02-02 21:25:26

TeoBigusGeekus
BL DieHard
From: /Greece/Kastoria
Registered: 2015-10-04
Posts: 1,466

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

All righty then!
Thanks for the feedback; I'll leave it be for a couple of days more in case it misbehaves and then I'll update the repo.


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

#3959 2021-02-06 09:52:28

unklar
Member
Registered: 2015-10-31
Posts: 1,364

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

^^Secretly, after the release of the new Moongiant, I was hoping to put you on this trail and ask you to take a look if you could help us out therewink

Unfortunately, as is so often the case, new trouble is already looming with a 'daily_forecast' that has been incomplete for three days. So they've tinkered with it again and are mangling your script.  cry

viOqH8St.png

Offline

#3960 2021-02-07 22:57:18

TeoBigusGeekus
BL DieHard
From: /Greece/Kastoria
Registered: 2015-10-04
Posts: 1,466

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

Daily forecast is OK here.
Maybe your German version?

Last edited by TeoBigusGeekus (2021-02-19 08:10:57)


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

#3961 2021-02-08 07:23:40

morfik
Member
From: Europe/Poland
Registered: 2016-09-08
Posts: 152
Website

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

To me the daily forecast looks broken:

TwIrtqe.png

Offline

#3962 2021-02-08 07:28:58

TeoBigusGeekus
BL DieHard
From: /Greece/Kastoria
Registered: 2015-10-04
Posts: 1,466

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

I'll investigate further then.


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

#3963 2021-02-08 15:12:28

KairiTech
New Member
Registered: 2021-02-08
Posts: 4

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

Doesn't seem to work for Toronto either. Here's a snip from daily_forecast - lines 33, 34, 35, 36:

WinterCast
See detailed snow and ice outlook
Friday
2/12

And this is a snip from the Kastora daily_forecast - same lines, which seems to work fine:

-2
Mild with sunshine
0%
Saturday

Also, for Toronto the forecast_2016 directory only gets two or three of the icons but for Kastora all of the icons seem to be there.

Last edited by KairiTech (2021-02-08 15:16:09)

Offline

#3964 2021-02-08 22:45:16

TeoBigusGeekus
BL DieHard
From: /Greece/Kastoria
Registered: 2015-10-04
Posts: 1,466

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

Good call Kairitech.
The lines

WINTERCAST
See detailed snow and ice outlook

are creating the havoc, so I guess you guys have to leave your miserable, cold countries and emigrate to Greece.
Alternatively, add this line

sed -i '/WinterCast/,+1 d' $HOME/Accuweather_conky_script/daily_forecast

after line 415 of the script (just before the for loop)...


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

#3965 2021-02-08 23:05:15

il.harun
Member
Registered: 2020-06-04
Posts: 24

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

there is a new block in daily_forecast raw:

<div class="daily-wintercast-cta">
	<a class="daily-wintercast-cta__inner inline-cta-banner winter" href="/en/ru/moscow/294021/winter-weather-forecast/294021">
				<div class="banner-content">
					<h3 class="banner-header">
						WinterCast
					</h3>
					<p class="banner-text">
						See detailed snow and ice outlook
					</p>
				</div>
				<svg class="chevron-icon right" xmlns="http://www.w3.org/2000/svg" width="10" height="6" viewBox="0 0 10 6"><path d="M10 .969L9.037 0 5 4.063.963 0 0 .969 5 6z" /></svg>
			</a>
</div>

I just deleted it,
script accuweather:

	#Daily forecast
	if [[ -s $HOME/Accuweather_conky_script/daily_forecast ]]; then
		sed -i '/<div class="daily-wrapper" data-qa="dailyCard0">/,/Further Ahead/!d' $HOME/Accuweather_conky_script/daily_forecast

		sed -i '/<div class="daily-wintercast-cta">/,/div class="daily-wrapper"/d' $HOME/Accuweather_conky_script/daily_forecast

		sed -i -e 's/^.*dow date">//g' -e 's/^.*sub date">//g' -e 's/^.*weathericons\///g' -e 's/\.svg.*$//g' -e 's/^.*"high">//g' -e 's/^.*"low">\///g' -e 's/&#xB0;<\/span>//g' -e 's/<\/span>//g' -e '/<\|>\|fill=\|^[ \|\t]*$\|Further Ahead/d' -e 's/^[ \|\t]*//g' $HOME/Accuweather_conky_script/daily_forecast

Offline

#3966 2021-02-08 23:11:52

TeoBigusGeekus
BL DieHard
From: /Greece/Kastoria
Registered: 2015-10-04
Posts: 1,466

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

Yeah, I know il.harun, thanks.


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

#3967 2021-02-08 23:20:36

TeoBigusGeekus
BL DieHard
From: /Greece/Kastoria
Registered: 2015-10-04
Posts: 1,466

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

ANNOUNCEMENT
Moongiant script changed to comply to the page's new layout. Major cleanup of the code and conkyrc files rewritten (thanks unklar).
The downloaded info is less now; in order to obtain the previous info, the script would have to download four more pages - no way!

Last edited by TeoBigusGeekus (2021-02-09 06:21:07)


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

#3968 2021-02-09 06:13:57

morfik
Member
From: Europe/Poland
Registered: 2016-09-08
Posts: 152
Website

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

TeoBigusGeekus wrote:

Good call Kairitech.
Alternatively, add this line

sed -i '/WinterCast/,+1 d' $HOME/Accuweather_conky_script/daily_forecast

after line 415 of the script (just before the for loop)...

It works, thanks. smile

Offline

#3969 2021-02-09 06:22:30

TeoBigusGeekus
BL DieHard
From: /Greece/Kastoria
Registered: 2015-10-04
Posts: 1,466

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

So, no emigration plans? tongue


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

#3970 2021-02-09 06:23:25

morfik
Member
From: Europe/Poland
Registered: 2016-09-08
Posts: 152
Website

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

Maybe to Norway. smile

Offline

#3971 2021-02-09 06:52:22

TeoBigusGeekus
BL DieHard
From: /Greece/Kastoria
Registered: 2015-10-04
Posts: 1,466

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

I'll come and visit you... In the summer..


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

#3972 2021-02-09 09:29:24

unklar
Member
Registered: 2015-10-31
Posts: 1,364

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

QIPb2j5t.png

^Teo, perfect.  smile

I would emigrate to Scotland. Unfortunately, in the meantime:
- too old  roll
- the "EU" is building more and more obstacles in its act of defiance
- I would see my grandchildren only with difficulty (Schengen is pass`e)  monkey

but, it's freezing cold   big_smile

Offline

#3973 2021-02-09 13:57:44

KairiTech
New Member
Registered: 2021-02-08
Posts: 4

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

TeoBigusGeekus wrote:

Good call Kairitech.
The lines

WINTERCAST
See detailed snow and ice outlook

are creating the havoc, so I guess you guys have to leave your miserable, cold countries and emigrate to Greece.
Alternatively, add this line

sed -i '/WinterCast/,+1 d' $HOME/Accuweather_conky_script/daily_forecast

after line 415 of the script (just before the for loop)...

Thanks Teo it works perfectly now and thanks for your dedication in keeping your scripts alive.

I grew up in The Caribbean but I love my snow now.  I'd honestly miss it but if I had to immigrate again Greece would at the top of the list.

Offline

#3974 2021-02-09 21:57:04

TeoBigusGeekus
BL DieHard
From: /Greece/Kastoria
Registered: 2015-10-04
Posts: 1,466

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

@unklar
We'll get a small taste of that in a few days

@kairiTech
The Caribbean? Lovely, here's some Greek reggae.


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

#3975 2021-02-10 09:27:00

unklar
Member
Registered: 2015-10-31
Posts: 1,364

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

TeoBigusGeekus wrote:

@unklar
We'll get a small taste of that in a few days

Be glad that it is not (yet) as cold as it is here.
We had -16.9°C this morning and it's supposed to stay that way for another week.   big_smile

Offline

Board footer

Powered by FluxBB