>>>>http://htmelek.republika.pl/ >Universal ConfConky v. 002 <<<<
>>>>http://htmelek.republika.pl/ >Universal ConfConky v. 002 <<<<
Last edited by grzegorzdabrowka; May 7th, 2013 at 10:54 PM.
Hi there, i'm kinda new here, so if this post is in a bad section, i'm sorry for that
So, i tried to use conky for viewing my google calendar, using a .conkyrc file as follows /found that one in a how-to somewhere/:
alignment top_right
background no
border_width 0
cpu_avg_samples 2
default_color white
default_outline_color white
default_shade_color white
draw_borders no
draw_graph_borders yes
draw_outline no
draw_shades no
use_xft yes
xftfont DejaVu Sans Mono:size=12
gap_x 5
gap_y 60
minimum_size 5 5
net_avg_samples 2
double_buffer yes
out_to_console no
out_to_stderr no
extra_newline no
own_window yes
own_window_class Conky
own_window_type override
own_window_transparent yes
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager
stippled_borders 0
update_interval 1.0
uppercase no
use_spacer none
show_graph_scale no
show_graph_range no
text_buffer_size 8096
TEXT
${execi 300 gcalcli --nc --cals=owner calw 4}
but when i run conky from terminal, the output looks like this:Code:
jakub@jakub-AO531h ~ $ conkyConky: desktop window (e00029) is subwindow of root window (ab)
Conky: window type - override
Conky: drawing to created window (0x3000001)
Conky: drawing to double buffer
Traceback (most recent call last):
File "/usr/bin/gcalcli", line 1524, in <module>
BowChickaWowWow()
File "/usr/bin/gcalcli", line 1469, in BowChickaWowWow
gcal.CalQuery(args[0], count=int(args[1]))
File "/usr/bin/gcalcli", line 1011, in CalQuery
self._GraphEvents(cmd, start, count, eventList)
File "/usr/bin/gcalcli", line 712, in _GraphEvents
PrintMsg(CLR_NRM(), line + "\n")
File "/usr/bin/gcalcli", line 239, in PrintMsg
sys.stdout.write(unicode(msg, 'UTF-8'))
TypeError: decoding Unicode is not supported
I've read many websites about this, yet still haven't found a solution, if i delete the .conkyrc file, conky works /then it looks like in an enclosed screenshot/.Screenshot from 2013-05-08 08:19:32.png
Thanks for any help
J.
Last edited by Jacoobic; May 8th, 2013 at 09:07 AM.
maybe like this:
Code:# ${Font}Ethernet Private IP:${alignr}${addr eth0} ${outlinecolor black}${color1}${font Heydings Icons:bold:size=8}d${outlinecolor}${font}\ ${if_match "${downspeedf eth0}" > "0"}${color green}|\ ${if_match "${downspeedf eth0}" > "19"}${color blue}|\ ${if_match "${downspeedf eth0}" > "38"}${color black}|\ ${if_match "${downspeedf eth0}" > "58"}${color green}|\ ${if_match "${downspeedf eth0}" > "77"}${color green}|\ ${if_match "${downspeedf eth0}" > "96"}${color green}|\ ${if_match "${downspeedf eth0}" > "115"}${color red}|\ ${if_match "${downspeedf eth0}" > "134"}${color green}|\ ${if_match "${downspeedf eth0}" > "154"}${color green}|\ ${if_match "${downspeedf eth0}" > "173"}${color yellow}|\ ${if_match "${downspeedf eth0}" > "192"}${color green}|\ ${else}${color grey}${color}${endif}\ ${else}${color grey}|${color}${endif}\ ${else}${color grey}||${color}${endif}\ ${else}${color grey}|||${color}${endif}\ ${else}${color grey}||||${color}${endif}\ ${else}${color grey}||||||${color}${endif}\ ${else}${color grey}|||||||${color}${endif}\ ${else}${color grey}||||||||${color}${endif}\ ${else}${color grey}|||||||||${color}${endif}\ ${else}${color grey}||||||||||${color}${endif}\ ${downspeedf eth0} # ${outlinecolor black}${color1}${font Heydings Icons:bold:size=8}u${outlinecolor}${font}\ ${if_match ${upspeedf eth0} == 0}${color grey}|||||||||||${color}${else}\ ${if_match ${upspeedf eth0} <= 4.8}${color green}|${color grey}||||||||||${color}${else}\ ${if_match ${upspeedf eth0} <= 9.6}${color green}||${color grey}|||||||||${color}${else}\ ${if_match ${upspeedf eth0} <= 14}${color green}|||${color grey}||||||||${color}${else}\ ${if_match ${upspeedf eth0} <= 19}${color green}||||${color grey}|||||||${color}${else}\ ${if_match ${upspeedf eth0} <= 24}${color green}|||||${color grey}||||||${color}${else}\ ${if_match ${upspeedf eth0} <= 29}${color green}||||||${color grey}|||||${color}${else}\ ${if_match ${upspeedf eth0} <= 34}${color green}|||||||${color grey}||||${color}${else}\ ${if_match ${upspeedf eth0} <= 38}${color green}||||||||${color grey}|||${color}${else}\ ${if_match ${upspeedf eth0} <= 43}${color green}|||||||||${color grey}||${color}${else}\ ${if_match ${upspeedf eth0} < 48}${color green}||||||||||${color grey}|${color}${else}\ ${if_match ${upspeedf eth0} >= 48}${color green}|||||||||||${color}\ ${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}\ ${upspeedf eth0}${alignr}${totalup eth0} # #http://htmelek.republika.pl/
Last edited by grzegorzdabrowka; May 8th, 2013 at 02:48 PM.
Maybe a bug in gcalcli or something has changed at google's end.
Never used gcalcli.
If you delete your ~/.conkyc file, conky will use a sample config @ /etc/conky/conky.conf as shown in your pic.
Test gcalcli in terminal...
eg
My outputCode:gcalcli --nc --user <google login name> --pw <password> calm
In terminal for gcalcli usage...Code:glen@Raring:~$ gcalcli --nc --user xxxx --pw xxxxx calm +----------+----------+----------+----------+----------+----------+----------+ |May 2013 | +----------+----------+----------+----------+----------+----------+----------+ |Sunday |Monday |Tuesday |Wednesday |Thursday |Friday |Saturday | +----------+----------+----------+----------+----------+----------+----------+ | | | |01 |02 |03 |04 | | | | | | | | | Traceback (most recent call last): File "/usr/bin/gcalcli", line 1524, in <module> BowChickaWowWow() File "/usr/bin/gcalcli", line 1486, in BowChickaWowWow gcal.CalQuery(args[0]) File "/usr/bin/gcalcli", line 1011, in CalQuery self._GraphEvents(cmd, start, count, eventList) File "/usr/bin/gcalcli", line 712, in _GraphEvents PrintMsg(CLR_NRM(), line + "\n") File "/usr/bin/gcalcli", line 239, in PrintMsg sys.stdout.write(unicode(msg, 'UTF-8')) TypeError: decoding Unicode is not supported
Code:gcalcli --help
Last edited by stinkeye; May 8th, 2013 at 12:37 PM.
gcalcli works okay in terminal, problem arises only when using conky....
Hi,
I ran your rc on my machine and it ran fine after putting my username and password in like this:
You may need to add:Code:${execi 300 gcalcli --nc --cals= --user xxxxxxxxxxxxxx@gmail.com --pw yyyyyyyy calw 4}
into the config settings above:Code:override_utf8_locale yes
for your particular installation/location. Otherwise, I'm not sure.Code:TEXT
Last edited by stylintile; May 8th, 2013 at 12:47 PM. Reason: added screenshot
already tried the override utf8 part, alas to no result.....anyway, somebody has told me i shoud update gcalcli to v3.1, so now i don't get the decoding error, but also nothing else.....calendar doesn't show, the process stops like this:
and then there's nothing else.....jakub@jakub-AO531h ~ $ conky
Conky: desktop window (e00029) is subwindow of root window (ab)
Conky: window type - override
Conky: drawing to created window (0x2c00001)
Conky: drawing to double buffer
Last edited by Jacoobic; May 8th, 2013 at 01:00 PM.
Sorry I took so long to get back. I just got home from work.
The conky that runs if you delete the gcal rc is the default conky config which should be located at etc/conky and is named conky.conf. Since it seems to display correctly, you might try replacing everything above "TEXT" in your conky with what is in the default conky.conf. Also, how are you running it? I always run mine in the terminal first (for troubleshooting) with:
Let us know if that works.Code:conky -d -c /path/to_your/conky_rc
Excellent idea! Your code is much easier to follow than my original code, but I found a few logic problems.
First, there should be no colored bars displayed when the speed is zero (yours displays 1 bar).
Screenshot - 05082013 - 05:54:03 PM.png (your code results are on top)
This can be fixed by adding an ifmatch statement for downspeed == 0.
Also by using quotes ("") around "ifmatch" and the "numbers"; the downspeeds above 0 and below 10kb/s in your code displays five bars when it should only display one (at least on my system anyway).
Screenshot - 05082013 - 05:51:33 PM.png
There was also a problem with color when the speed reached maximum, placing ${color} in the last line fixed it.
I was able to clean it up a little more and get everything working with the following code.
But, conky complains there is an endif missing (conky still runs, it just complains about it). I can't figure out where the last endif should go, every place I try to put it causes output to malfunction. So if anyone can figure out how to improve it a bit further by getting rid of the unmatched if_match (aside from my original solution) please let me know.Code:${Font}Ethernet Private IP:${alignr}${addr eth0} ${outlinecolor black}${color1}${font Heydings Icons:bold:size=8}d${outlinecolor}${font}\ ${if_match ${downspeedf eth0} == 0}\ ${if_match ${downspeedf eth0} > 0}${color green}|\ ${if_match ${downspeedf eth0} > 19}${color green}|\ ${if_match ${downspeedf eth0} > 38}${color green}|\ ${if_match ${downspeedf eth0} > 58}${color green}|\ ${if_match ${downspeedf eth0} > 77}${color green}|\ ${if_match ${downspeedf eth0} > 96}${color yellow}|\ ${if_match ${downspeedf eth0} > 115}${color yellow}|\ ${if_match ${downspeedf eth0} > 134}${color yellow}|\ ${if_match ${downspeedf eth0} > 154}${color red}|\ ${if_match ${downspeedf eth0} > 173}${color red}|\ ${if_match ${downspeedf eth0} >= 192}${color red}|\ ${else}${color grey}|${endif}\ ${else}${color grey}||${endif}\ ${else}${color grey}|||${endif}\ ${else}${color grey}||||${endif}\ ${else}${color grey}|||||${endif}\ ${else}${color grey}||||||${endif}\ ${else}${color grey}|||||||${endif}\ ${else}${color grey}||||||||${endif}\ ${else}${color grey}|||||||||${endif}\ ${else}${color grey}||||||||||${endif}\ ${else}${color grey}|||||||||||${endif}\ ${color}${downspeedf eth0}
Of course my original way isn't too bad with some back slashes added in...
But I like your method more due to easier color control.Code:Ethernet Private IP:${alignr}${addr eth0} ${outlinecolor black}${color1}${font Heydings Icons:bold:size=8}d\ ${outlinecolor}${font}${color} ${voffset -2}[\ ${if_match ${downspeedf eth0} == 0}${color6}|||||||||||${else}\ ${if_match ${downspeedf eth0} <= 19}${color5}|${color6}||||||||||${else}\ ${if_match ${downspeedf eth0} <= 38}${color5}||${color6}|||||||||${else}\ ${if_match ${downspeedf eth0} <= 58}${color5}|||${color6}||||||||${else}\ ${if_match ${downspeedf eth0} <= 77}${color5}||||${color6}|||||||${else}\ ${if_match ${downspeedf eth0} <= 96}${color5}|||||${color6}||||||${else}\ ${if_match ${downspeedf eth0} <= 115}${color5}||||||${color6}|||||${else}\ ${if_match ${downspeedf eth0} <= 134}${color5}|||||||${color6}||||${else}\ ${if_match ${downspeedf eth0} <= 154}${color5}||||||||${color6}|||${else}\ ${if_match ${downspeedf eth0} <= 173}${color5}|||||||||${color6}||${else}\ ${if_match ${downspeedf eth0} < 192}${color5}||||||||||${color6}|${else}\ ${if_match ${downspeedf eth0} >= 192}${color5}|||||||||||\ ${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}\ ${color}] ${alignr}${font}${totaldown eth0} # ${outlinecolor black}${color1}${font Heydings Icons:bold:size=8}u\ ${outlinecolor}${color}${font} ${voffset -2}[\ ${if_match ${upspeedf eth0} == 0}${color6}|||||||||||${else}\ ${if_match ${upspeedf eth0} <= 5}${color5}|${color6}||||||||||${else}\ ${if_match ${upspeedf eth0} <= 10}${color5}||${color6}|||||||||${else}\ ${if_match ${upspeedf eth0} <= 14}${color5}|||${color6}||||||||${else}\ ${if_match ${upspeedf eth0} <= 19}${color5}||||${color6}|||||||${else}\ ${if_match ${upspeedf eth0} <= 24}${color5}|||||${color6}||||||${else}\ ${if_match ${upspeedf eth0} <= 29}${color5}||||||${color6}|||||${else}\ ${if_match ${upspeedf eth0} <= 34}${color5}|||||||${color6}||||${else}\ ${if_match ${upspeedf eth0} <= 38}${color5}||||||||${color6}|||${else}\ ${if_match ${upspeedf eth0} <= 43}${color5}|||||||||${color6}||${else}\ ${if_match ${upspeedf eth0} < 48}${color5}||||||||||${color6}|${else}\ ${if_match ${upspeedf eth0} >= 48}${color5}|||||||||||\ ${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}${endif}\ ${color}] ${alignr}${font}${totalup eth0}
Last edited by Petro Dawg; May 9th, 2013 at 01:28 AM.
Who's Awesome? You're Awesome.
This is absolutely beautiful. As my first post in this forum goes to you!! Should tell you something . I have been trying to get a weather section like your's for ever and a day. If you
I've just started messing around with conky configs. But this is what I've worked up so far.
I use my Linux drive mostly to fold on, thats why the work unit progree is there. Since I have fallen in love with Kubuntu. So now I'm only using that on my laptop.
Last edited by gizmoid; May 11th, 2013 at 02:16 AM.
Bookmarks