Conky thread, show your work!

how-to
conky

#115

Mmmmh. This is a good question. A question that i can not answer. Sorry. :frowning:
I`m not a an expert too. Do you ask @oberon? Sorry, that i cant help now.


#116

When the chonky executes this line
Battery: ${battery_percent BAT1}% ${alignr}${battery_bar 8,70 BAT1}
knows where the folder is in the system, but you must identify yourself if is BAT1 or BAT0


#117
[rvc@acer-e15 ~]$ inxi -Fxb | grep Battery
Battery    BAT1: charge: 57.0 Wh 100.0% condition: 57.0/56.0 Wh (102%)
[rvc@acer-e15 ~]$ lsmod | grep acpi
intel_lpss_acpi        16384  0
acpi_pad               20480  0
intel_lpss             16384  2 intel_lpss_pci,intel_lpss_acpi
[rvc@acer-e15 ~]$ lsmod | grep battery
battery                20480  0
[rvc@acer-e15 ~]$

#118

I can’t confirm, but you can test this script for your battery:

#..: BATTERY :..
${color d7d7d7}${offset 100}${voffset -8}${cpugraph cpu6 17,1}${voffset -3}${hr 2}${color3}
${offset 150}${voffset -10} ${font neuropol:size=20}${battery_percent BAT0}%${font Nimbus Mono L:size=8 style=bold}  Battery
${offset 160}${voffset -5}${cpubar cpu6 0, 150}${voffset 2}${color1}
${offset 160}..:: ${acpiacadapter} ::..
${battery_time BAT0}

#119

Script works when i executed but BAT1 instead of BAT0 [as mentioned in my inxi before]
now i need to work this out to make cronograph-conky change LED blink color !
thank you so much :slight_smile:


#120

combined and configured a common script so the wttr weather also integrated along with battery [it remains to be seen on how cronograph-conky displays !]

CONKY_CONFIG

######################
# - Conky settings - #
######################
update_interval 1
total_run_times 0
net_avg_samples 1
cpu_avg_samples 1

imlib_cache_size 0
double_buffer yes
no_buffers yes

#####################
# - Text settings - #
#####################
use_xft yes
xftfont Dinreg:size=180
override_utf8_locale yes
text_buffer_size 2048
xftalpha 0.9

#############################
# - Window specifications - #
#############################
own_window_class Conky
own_window yes
own_window_type normal
#own_window_transparent yes
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager
own_window_argb_visual yes
own_window_argb_value 0

alignment tl
gap_x 5
gap_y 5
minimum_size 290 200


default_bar_size 60 8

#########################
# - Graphics settings - #
#########################
draw_shades no

default_color BDBFA1
default_shade_color 090909
color0 ffffff
color1 e9e0e5
color2 fedcba
color3 142A41
color4 ffafcf
color5 ffcdaa


#lua_load ~/.conky/conkybg.lua
#lua_draw_hook_pre conky_draw_bg

TEXT
${voffset -250}${font Dinreg:size=13}${color5}${if_match ${time %H}<12}AM${else}${if_match ${time %H}>12}PM${endif}${endif} ${color}${font}
${color4}${voffset -390}${time %I}${color}
${color2}${voffset -170}${time %M}${color}
${color1}${voffset -290}${font Droid Sans:size=16}${time %A}
${time %B .%d}
${alignr}${font nimbus mono:bold:pixelsize=18}${color5}${execi 900 curl -s 'wttr.in/#MY_TOWN#?0TKm'}

${color3}${offset 100}${voffset -8}${cpugraph cpu6 17,1}${voffset -3}${hr 2}${color3}
${offset 150}${voffset -10} ${font neuropol:size=20}${battery_percent BAT1}%${font Nimbus Mono PS:bold:pixelsize=18}  Battery
${offset 160}${voffset -5}${cpubar cpu6 0, 150}${voffset 2}${color1}
${offset 160}..:: ${acpiacadapter} ::..
${battery_time BAT1}

TOP LEFT DIGITAL CLOCK “Cowon Clock” from dA
BOTTOM RIGHT CRONOGRAPH from AUR

Cronograph Conky fails to change color in BAT 1.
the script says IF AC PLUGGED IN, Display PWR else BAT
then the Color rings come into place… any Clue?


#122

the config you posted works fine as displayed above…

cronograph current config related to battery is as follows

${voffset 23}${goto 160}${font hooge 05_53:size=7:bold:italic}${if_empty ${battery BAT1}}PWR${else}BAT${endif}${font}:

${if_empty ${battery}}
# At first, we assume that there's no battery so the led is always pink
${image /opt/cronograph_blk/images/Pink.png -p 184,25 -s 30x30}
${else}${if_match ${battery_percent BAT1} > 60}${image /opt/cronograph_blk/images/Dark_Green.png -p 184,25-s 30x30}
${else}${if_match ${battery_percent BAT1} > 45}${image /opt/cronograph_blk/images/Green.png -p 184,25-s 30x30}
${else}${if_match ${battery_percent BAT1} > 30}${image /opt/cronograph_blk/images/Yellow.png -p 184,25-s 30x30}
${else}${if_match ${battery_percent BAT1} > 20}${image /opt/cronograph_blk/images/Orange.png -p 184,25-s 30x30}
${else}${if_match ${battery_percent BAT1} > 15}${image /opt/cronograph_blk/images/Purple.png -p 184,25-s 30x30}
${else}${image /opt/cronograph_blk/images/Red.png -p 184,25-s 30x30}${endif}${endif}${endif}${endif}${endif}
${endif}
${execpi 1 cat /opt/cronograph_blk/scripts/blinkingLED}

led fail to change color


#123

playing around i3 config for same display as above…

CONKY

######################
# - Conky settings - #
######################
update_interval 1
total_run_times 0
net_avg_samples 1
cpu_avg_samples 1

imlib_cache_size 0
double_buffer yes
no_buffers yes

#####################
# - Text settings - #
#####################
use_xft yes
xftfont Dinreg:size=180
override_utf8_locale yes
text_buffer_size 2048
xftalpha 0.9

#############################
# - Window specifications - #
#############################
own_window_class Conky
own_window yes
own_window_type override
#own_window_transparent yes
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager
own_window_argb_visual yes
own_window_argb_value 0

alignment tr
gap_x 2
gap_y 20
minimum_size 290 200


default_bar_size 60 8

#########################
# - Graphics settings - #
#########################
draw_shades no

default_color c3d897
default_shade_color e0e0e0
color0 f49043 # ambiance default
color1 e9e0e5 # off white silvery
color2 42a2da # bluish
color3 df272c # reddish
color4 eaff02 # yellow
color5 21ab1e # green
color6 85273a # dark maroon
color7 823b99 # purple
color8 905a3b # brown
color9 274865 # navyblue

#lua_load ~/.conky/conkybg.lua
#lua_draw_hook_pre conky_draw_bg

TEXT
${alignr}${voffset -200}${font Dinreg:size=13}${color6}${if_match ${time %H}<12}AM${else}${if_match ${time %H}>12}PM${endif}${endif} ${color}${font}
${alignr}${offset -75}${color3}${voffset -320}${time %I}${color}
${alignr}${color0}${voffset -140}${time %M}${color}
${alignr}${color1}${voffset -240}${font Droid Sans:size=16}${time %A}
${alignr}${time %B .%d}
${alignr}${font nimbus mono:bold:pixelsize=18}${color4}${execi 900 curl -s 'wttr.in/#YOUR_CITY#i?0TKm'}

${color1}${offset 100}${voffset -8}${cpugraph cpu6 17,1}${voffset -3}${hr 2}${color3}
${color6}${alignr}${voffset 5}Battery Status : ${voffset -5}${voffset -1} ${font neuropol:size=20}${battery_percent BAT0}%${font Nimbus Mono PS:bold:pixelsize=18}
${alignr}${color orange}${offset -3}${voffset -5}${cpubar cpu6 0, 150}${voffset 2}${color6}
${alignr}${color9}${texeci 60 acpi -i | head -1 | cut -b 12-50}

#124

Do you have those images in that folder?

Do you have that script in that folder and the right to execute it?

If you mixed the install with “local” stuff that point to your “${HOME}” user might create some problems. Be assured that inside the code is pointing to the right place …


#125

yes…
as its installed from AUR, pkgbuild and all are in the right place…


#127

atlast the cronograph works fine as it should ! installed from AUR

changes in the cronograph for battery / power plugged in needed to be edited to current syntax

code for battery / power [Display in “BAT” or “PWR” if or not plugged in

${offset -2}${voffset 23}${goto 118}${font hooge 05_53:size=6:bold:italic}${if_match "on-line"== "${texeci 10 acpi -a | tail -c8}"="on-line"}PWR${else}BAT${endif}${offset 25}${battery_percent BAT1}%${font}

code for LED color change w.r.t available battery percentage

${if_empty "${acpi -b}"}
#At first, we assume that there's no battery so the led is always blank
${image /opt/cronograph_blk/images/Dark_Purple.png -p 135,25 -s 30x30} \ 
${else}
${if_match "${battery_percent BAT1}">="60"}${image /opt/cronograph_blk/images/Dark_Green.png -p 135,25-s 30x30}${endif}
${if_match "${battery_percent BAT1}">="45"}${if_match "${battery_percent BAT1}"<="59"}${image /opt/cronograph_blk/images/Green.png -p 135,25-s 30x30}${endif}${endif}
${if_match "${battery_percent BAT1}">="35"}${if_match "${battery_percent BAT1}"<="44"}${image /opt/cronograph_blk/images/Yellow.png -p 135,25-s 30x30}${endif}${endif}
${if_match "${battery_percent BAT1}">="25"}${if_match "${battery_percent BAT1}"<="34"}${image /opt/cronograph_blk/images/Orange.png -p 135,25-s 30x30}${endif}${endif}
${if_match "${battery_percent BAT1}">="15"}${if_match "${battery_percent BAT1}"<="24"}${image /opt/cronograph_blk/images/Purple.png -p 135,25-s 30x30}${endif}${endif}
${if_match "${battery_percent BAT1}">="10"}${if_match "${battery_percent BAT1}"<="14"}${image /opt/cronograph_blk/images/Red.png -p 135,25-s 30x30}${endif}${endif}
${endif}
##${execpi 1 cat /opt/cronograph_blk/scripts/blinkingLED}

other config same as available, edited to suit resolution…


#128

I’d like to know what you used on the pnael on top to show the informations.


#129

if post #109 is what you mean, thats i3-blocks in combo with conky-cli to pipe info into panel. can google for i3-blocks to edit your i3-blocks script to pipe what info you want…
LINK 1 & LINK 2 if that can be of help…


#130


My current setup, Star Wars style :slight_smile: It uses the ConkyColors and Starkiller fonts.

The conky script

# -- Conky settings -- #

update_interval 1
total_run_times 0
net_avg_samples 1
cpu_avg_samples 1
if_up_strictness link

imlib_cache_size 0
double_buffer yes
no_buffers yes

format_human_readable


# -- Text settings -- #

use_xft yes
xftfont Starkiller:size=6
override_utf8_locale yes
text_buffer_size 2048
short_units yes


# -- Window specifications -- #

own_window_class Conky
own_window yes
own_window_type normal
own_window_transparent yes
own_window_argb_visual yes
own_window_argb_value 200
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager

alignment top_right
gap_x 0
gap_y 0
minimum_size 567 800
maximum_width 567

default_bar_size 60 8


# -- Graphics settings -- #

draw_shades no

default_color aaaaaa

color0 white
color1 ffff00
color2 white
color3 ffff00


# -- Lua Load -- #

lua_load ~/.conky/starwars/scripts/clock_rings.lua
lua_draw_hook_pre clock_rings


TEXT
${goto 410}${voffset 12}${color3}${font Starkiller Outline:style=Standard:size=20}system${font}${color}
# |--BASIC INFO
${voffset 20}${goto 358}${color0}${voffset 7}${offset 4}${font ConkyColorsLogos:size=9}a${font}${color}${voffset -16}
${goto 358}${color0}${font ConkyColors:size=16}b${font}${color}
${goto 390}${voffset -23}Kernel: ${alignr 10}${color1}${kernel}${color}
${goto 390}Os: ${alignr 10}${color1}Manjaro (Arch)${color}
${goto 390}Uptime: ${alignr 10}${color1}${uptime}${color}
# |--LUA LOGOS, CLOCK, WEATHER
${goto 40}${voffset -35}${font ConkyColors:size=15}i${font}${goto 177}${voffset 18}${font ConkyColors:size=15}6${font}${goto 260}${voffset -38}${font ConkyColors:size=15}l${font}
${voffset 42}${goto 104}${font ConkyColors:size=15}g${font}${alignr 70}${voffset -22}${color0}${font Starkiller:size=12}${time %H:%M}${font}${color}${goto 390}${voffset -2}${time %A, %d %b %Y}
${goto 358}${voffset 5}${color0}${font ConkyColorsWeather:size=15}${execi 300 ~/.conky/starwars/scripts/conkyweather.sh "EUR|NL|NLD528|*City*"}${font}${color}${goto 390}${voffset -12}${execi 5 cat ~/.conky/starwars/scripts/conkyweather.conf}
${goto 177}${voffset 15}${font ConkyColors:size=15}e${font}
${goto 150}${voffset 68}${font ConkyColors:size=15}k${font}
${voffset -176}${goto 275}${hr 2}
${voffset 50}${goto 275}${hr 2}
# |--CPU
${goto 358}${voffset 5}${color0}${font ConkyColors:size=16}e${font}${offset -20}${voffset 6}${cpubar cpu0 4,17}${color}${voffset -18}${goto 390}CPU1: ${goto 422}${color1}${freq_g 1}${goto 448}GHz${alignr}${offset -12}${cpu cpu1}%${alignr 10}${color2}${cpugraph cpu1 8,60 ffff00 ffff00}${color}
${goto 390}CPU2: ${goto 422}${color1}${freq_g 2}${goto 448}GHz${alignr}${offset -12}${color1}${cpu cpu2}%${alignr 10}${color2}${cpugraph cpu2 8,60 ffff00 ffff00}${color}
${goto 390}CPU3: ${goto 422}${color1}${freq_g 3}${goto 448}GHz${alignr}${offset -12}${color1}${cpu cpu3}%${alignr 10}${color2}${cpugraph cpu3 8,60 ffff00 ffff00}${color}
${goto 390}CPU4: ${goto 422}${color1}${freq_g 4}${goto 448}GHz${alignr}${offset -12}${color1}${cpu cpu4}%${alignr 10}${color2}${cpugraph cpu4 8,60 ffff00 ffff00}${color}
# |--CPU TEMP
${goto 358}${voffset 5}${color0}${font ConkyColors:size=15}8${font}${color}${goto 390}${voffset -12}temp core  1: ${alignr 65}${color1}${execi 10 sensors | grep 'Core 0' |cut -c 18-19}${goto 499}°C${color}
${goto 390}temp core 2: ${alignr 65}${color1}${execi 10 sensors | grep 'Core 1' |cut -c 18-19}${goto 499}°C${color}
${goto 390}temp gpu: ${alignr 65}${color1}${execi 10 sensors|grep temp1|cut -c 16-17}${goto 499}°C${color}
# |--MEM
${goto 358}${voffset 5}${color0}${font ConkyColors:size=15}g${font}${color}${goto 390}${voffset -12}RAM: ${color1}${memperc}%${color}
${goto 390}Free: ${color2}${memeasyfree}${color}${goto 468}Used: ${color2}${mem}${color}
# |--PROC
${goto 358}${voffset 5}${color0}${font ConkyColors:size=16}C${font}${color}${goto 390}${voffset -12}Processes: ${alignr 30}CPU${alignr 10}RAM
${voffset -1}${goto 390}${color2}${top name 1}${color}${color1} ${goto 492}${top cpu 1}${alignr 10}${top mem 1}${color}
${voffset -1}${goto 390}${color2}${top name 2}${color}${color1} ${goto 492}${top cpu 2}${alignr 10}${top mem 2}${color}
${voffset -1}${goto 390}${color2}${top name 3}${color}${color1} ${goto 492}${top cpu 3}${alignr 10}${top mem 3}${color}
${voffset -1}${goto 390}${color2}${top name 4}${color}${color1} ${goto 492}${top cpu 4}${alignr 10}${top mem 4}${color}
${voffset -1}${goto 390}${color2}${top name 5}${color}${color1} ${goto 492}${top cpu 5}${alignr 10}${top mem 5}${color}
# |--HDD
${goto 420}${voffset 10}${color3}${font Starkiller Outline:style=Standard:size=15}storage${font}${color}
${goto 358}${voffset 5}${color0}${font ConkyColors:size=15}i${font}${color}${goto 390}${voffset -12}root: ${color1}${fs_used_perc /}%${color}
${goto 390}Free: ${color2}${fs_free /}${color}${goto 468}Used: ${color2}${fs_used /}${color}
${goto 390}${voffset 3}home: ${color1}${fs_used_perc /home}%${color}
${goto 390}Free: ${color2}${fs_free /home}${color}${goto 468}Used: ${color2}${fs_used /home}${color}
${goto 390}${voffset 3}share: ${if_mounted /home/*user*/Mediashare}${color1}${fs_used_perc /home/*user*/Mediashare}%${color} ${alignr 10}${color0}${fs_bar 8,60 /home/*user*/Mediashare}${color}
${goto 390}Free: ${color2}${fs_free /home/*user*/Mediashare}${color}${goto 468}Used: ${color2}${fs_used /home/*user*/Mediashare}${color}${else}${color1}not mounted ${color}${endif}
# |--BATTERY
${goto 420}${voffset 10}${color3}${font Starkiller Outline:style=Standard:size=15}battery${font}${color}
${if_existing /sys/class/power_supply/BAT1}${goto 358}${voffset 3}${color0}${font ConkyColors:size=15}6${font}${color}${goto 390}${voffset -10}Battery: ${color1}${battery BAT1}${color}${else}${goto 358}${voffset 5}${color0}${font ConkyColors:size=15}6${font}${color}${goto 390}${voffset -6}Battery: ${color2}Unknown Status${color}${endif}
# |--AC
${if_existing /sys/class/power_supply/ACAD}${goto 390}AC: ${color1}${acpiacadapter ACAD}${color}${else}${goto 390}AC: ${color2}Unknown Status${color}${endif}
# |--TIME LEFT
${if_existing /sys/class/power_supply/BAT1}${goto 390}Time left: ${color1}${battery_time BAT1}${color}${else}${goto 390}Time left: ${color2}Unknown Status${color}${endif}
# |--NETWORK
${goto 415}${voffset 10}${color3}${font Starkiller Outline:style=Standard:size=15}network${font}${color}
# |--WLAN0
${if_up wlp5s0}${goto 358}${voffset 5}${color0}${font ConkyColors:size=15}l${font}${color}${goto 390}${voffset -12}Up: ${alignr}${offset -12}${color1}${upspeed wlp5s0}/s${color}${alignr 10}${color2}${upspeedgraph wlp5s0 8,60 ffff00 ffff00}${color}
${goto 390}Total: ${color2}${totalup wlp5s0}${color}
${goto 390}${voffset 3}Down: ${alignr}${offset -12}${color1}${downspeed wlp5s0}/s${color}${alignr 10}${color2}${downspeedgraph wlp5s0 8,60 ffff00 ffff00}${color}
${goto 390}Total: ${color2}${totaldown wlp5s0}${color}
${goto 358}${color0}${font ConkyColors:size=15}k${font}${color}${voffset -6}${goto 390}Signal: ${color1}${wireless_link_qual_perc wlp5s0}%${color}
${goto 358}${voffset 5}${color0}${font ConkyColors:size=15}B${font}${color}${goto 390}${voffset -12}Local IP: ${alignr 10}${color1}${addr wlp5s0}${color}
${goto 390}ESSID: ${alignr 10}${color1}${wireless_essid wlp5s0}${color}
# |--ENP4S0
${else}${if_up enp4s0}${goto 358}${voffset 5}${color0}${font ConkyColors:size=15}l${font}${color}${goto 390}${voffset -12}Up: ${alignr}${offset -12}${color1}${upspeed enp4s0}/s${color}${alignr 10}${color2}${upspeedgraph enp4s0 8,60 ffff00 ffff00}${color}
${goto 390}Total: ${color2}${totalup enp4s0}${color}
${goto 390}${voffset 3}Down: ${alignr}${offset -12}${color1}${downspeed enp4s0}/s${color}${alignr 10}${color2}${downspeedgraph enp4s0 8,60 ffff00 ffff00}${color}
${goto 390}Total: ${color2}${totaldown enp4s0}${color}
${goto 358}${voffset 4}${color0}${font ConkyColors:size=15}B${font}${color}${goto 390}${voffset -6}Local IP: ${alignr 10}${color1}${addr enp4s0}${color}
${else}${goto 358}${voffset 5}${color0}${font ConkyColors:size=15}q${font}${color}${voffset -6}${goto 390}${color1}Network Unavailable${color}${endif}${endif}

The lua script

--[[
Clock Rings by londonali1010 (2009)

This script draws percentage meters as rings, and also draws clock hands if you want! It is fully customisable; all options are described in the script. This script is based off a combination of my clock.lua script and my rings.lua script.

IMPORTANT: if you are using the 'cpu' function, it will cause a segmentation fault if it tries to draw a ring straight away. The if statement near the end of the script uses a delay to make sure that this doesn't happen. It calculates the length of the delay by the number of updates since Conky started. Generally, a value of 5s is long enough, so if you update Conky every 1s, use update_num > 5 in that if statement (the default). If you only update Conky every 2s, you should change it to update_num > 3; conversely if you update Conky every 0.5s, you should use update_num > 10. ALSO, if you change your Conky, is it best to use "killall conky; conky" to update it, otherwise the update_num will not be reset and you will get an error.

To call this script in Conky, use the following (assuming that you save this script to ~/scripts/rings.lua):
	lua_load ~/scripts/clock_rings-v1.1.1.lua
	lua_draw_hook_pre clock_rings

Changelog:
+ v1.1.1 -- Fixed minor bug that caused the script to crash if conky_parse() returns a nil value (20.10.2009)
+ v1.1 -- Added colour option for clock hands (07.10.2009)
+ v1.0 -- Original release (30.09.2009)
]]

settings_table = {
	--[[{
		-- Edit this table to customise your rings.
		-- You can create more rings simply by adding more elements to settings_table.
		-- "name" is the type of stat to display; you can choose from 'cpu', 'memperc', 'fs_used_perc', 'battery_used_perc'.
		name='time',
		-- "arg" is the argument to the stat type, e.g. if in Conky you would write ${cpu cpu0}, 'cpu0' would be the argument. If you would not use an argument in the Conky variable, use ''.
		arg='%I.%M',
		-- "max" is the maximum value of the ring. If the Conky variable outputs a percentage, use 100.
		max=12,
		-- "bg_colour" is the colour of the base ring.
		bg_colour=0xffffff,
		-- "bg_alpha" is the alpha value of the base ring.
		bg_alpha=0,
		-- "fg_colour" is the colour of the indicator part of the ring.
		fg_colour=0xffffff,
		-- "fg_alpha" is the alpha value of the indicator part of the ring.
		fg_alpha=0,
		-- "x" and "y" are the x and y coordinates of the centre of the ring, relative to the top left corner of the Conky window.
		x=160, y=155,
		-- "radius" is the radius of the ring.
		radius=50,
		-- "thickness" is the thickness of the ring, centred around the radius.
		thickness=5,
		-- "start_angle" is the starting angle of the ring, in degrees, clockwise from top. Value can be either positive or negative.
		start_angle=0,
		-- "end_angle" is the ending angle of the ring, in degrees, clockwise from top. Value can be either positive or negative, but must be larger than start_angle.
		end_angle=360
	},
	{
		name='time',
		arg='%M.%S',
		max=60,
		bg_colour=0xffffff,
		bg_alpha=0,
		fg_colour=0xffffff,
		fg_alpha=0,
		x=160, y=155,
		radius=56,
		thickness=5,
		start_angle=0,
		end_angle=360
	}, -- ]]
    
   
        
	{
		name='time',
		arg='%S',
		max=60,
		bg_colour=0xffffff,
		bg_alpha=0.1,
		fg_colour=0xffffff,
		fg_alpha=0.6,
		x=160, y=155,
		radius=65,
		thickness=4,
		start_angle=0,
		end_angle=360
	},
	{
		name='cpu',
		arg='cpu1',
		max=100,
		bg_colour=0xffffff,
		bg_alpha=0.2,
		fg_colour=0xffffff,
		fg_alpha=0.5,
		x=160, y=155,
		radius=75,
		thickness=5,
		start_angle=93,
		end_angle=208
	},
	{
		name='cpu',
		arg='cpu2',
		max=100,
		bg_colour=0xffffff,
		bg_alpha=0.2,
		fg_colour=0xffffff,
		fg_alpha=0.5,
		x=160, y=155,
		radius=81,
		thickness=5,
		start_angle=93,
		end_angle=208
	},

	{
                name='cpu',
                arg='cpu3',
                max=100,
                bg_colour=0xffffff,
                bg_alpha=0.2,
                fg_colour=0xffffff,
                fg_alpha=0.5,
                x=160, y=155,
                radius=87,
                thickness=5,
                start_angle=93,
                end_angle=208
        },

	{
                name='cpu',
                arg='cpu4',
                max=100,
                bg_colour=0xffffff,
                bg_alpha=0.2,
                fg_colour=0xffffff,
                fg_alpha=0.5,
                x=160, y=155,
                radius=93,
                thickness=5,
                start_angle=93,
                end_angle=208
        },
	{
		name='memperc',
		arg='',
		max=100,
		bg_colour=0xffffff,
		bg_alpha=0.2,
		fg_colour=0xffffff,
		fg_alpha=0.5,
		x=160, y=155,
		radius=84,
		thickness=22.5,
		start_angle=212,
		end_angle=329
	},
	{
		name='battery_percent',
		arg='BAT1',
		max=100,
		bg_colour=0xffffff,
		bg_alpha=0.2,
		fg_colour=0xffffff,
		fg_alpha=0.5,
		x=160, y=155,
		radius=84,
		thickness=22.5,
		start_angle=-27,
		end_angle=88
	},
	{
		name='cpu', -- dummy (used for arc)
		arg='',
		max=1,
		bg_colour=0xd5dcde,
		bg_alpha=0.7,
		fg_colour=0xd5dcde,
		fg_alpha=0,
		x=162, y=155,
		radius=118,
		thickness=2,
		start_angle=75,
		end_angle=105
	},
	{
		name='cpu', -- dummy (used for arc)
		arg='',
		max=1,
		bg_colour=0xffffff,
		bg_alpha=0.7,
		fg_colour=0xffffff,
		fg_alpha=0,
		x=266, y=155,
		radius=308,
		thickness=2,
		start_angle=84,
		end_angle=96
	},
	{
		name='fs_used_perc',
		arg='/',
		max=100,
		bg_colour=0xffffff,
		bg_alpha=0.2,
		fg_colour=0xffffff,
		fg_alpha=0.5,
		x=160, y=155,
		radius=105,
		thickness=5,
		start_angle=-120,
		end_angle=-1.5
	},
    {
    name='fs_used_perc',
		arg='/home',
		max=100,
		bg_colour=0xffffff,
		bg_alpha=0.2,
		fg_colour=0xffffff,
		fg_alpha=0.5,
		x=160, y=155,
		radius=111,
		thickness=5,
		start_angle=-120,
		end_angle=-1.5
	},
	{
		name='downspeedf',
		arg='wlp5s0',
		max=6000,
		bg_colour=0xffffff,
		bg_alpha=0.2,
		fg_colour=0xffffff,
		fg_alpha=0.5,
		x=160, y=155,
		radius=105,
		thickness=5,
		start_angle=1.5,
		end_angle=120
	},
    {
		name='upspeedf',
		arg='wlp5s0',
		max=6000,
		bg_colour=0xffffff,
		bg_alpha=0.2,
		fg_colour=0xffffff,
		fg_alpha=0.5,
		x=160, y=155,
		radius=111,
		thickness=5,
		start_angle=1.5,
		end_angle=120
	},
    {
		name='wireless_link_qual_perc',
		arg='wlp5s0',
		max=100,
		bg_colour=0xffffff,
		bg_alpha=0.2,
		fg_colour=0xffffff,
		fg_alpha=0.5,
		x=160, y=155,
		radius=108,
		thickness=11,
		start_angle=123,
		end_angle=237
	},
	
}

-- Use these settings to define the origin and extent of your clock.

clock_r=65

-- "clock_x" and "clock_y" are the coordinates of the centre of the clock, in pixels, from the top left of the Conky window.

clock_x=160
clock_y=155

-- Colour & alpha of the clock hands

clock_colour=0xffff00
clock_alpha=0.5

-- Do you want to show the seconds hand?

show_seconds=false

require 'cairo'

    
function rgb_to_r_g_b(colour,alpha)
	return ((colour / 0x10000) % 0x100) / 255., ((colour / 0x100) % 0x100) / 255., (colour % 0x100) / 255., alpha
    
end


function draw_ring(cr,t,pt)
	local w,h=conky_window.width,conky_window.height

	local xc,yc,ring_r,ring_w,sa,ea=pt['x'],pt['y'],pt['radius'],pt['thickness'],pt['start_angle'],pt['end_angle']
	local bgc, bga, fgc, fga=pt['bg_colour'], pt['bg_alpha'], pt['fg_colour'], pt['fg_alpha']

	local angle_0=sa*(2*math.pi/360)-math.pi/2
	local angle_f=ea*(2*math.pi/360)-math.pi/2
	local t_arc=t*(angle_f-angle_0)

	-- Draw background ring

	cairo_arc(cr,xc,yc,ring_r,angle_0,angle_f)
	cairo_set_source_rgba(cr,rgb_to_r_g_b(bgc,bga))
	cairo_set_line_width(cr,ring_w)
	cairo_stroke(cr)

	-- Draw indicator ring

	cairo_arc(cr,xc,yc,ring_r,angle_0,angle_0+t_arc)
	cairo_set_source_rgba(cr,rgb_to_r_g_b(fgc,fga))
	cairo_stroke(cr)
    
end



function draw_clock_hands(cr,xc,yc)
	local secs,mins,hours,secs_arc,mins_arc,hours_arc
	local xh,yh,xm,ym,xs,ys

	secs=os.date("%S")
	mins=os.date("%M")
	hours=os.date("%I")

	secs_arc=(2*math.pi/60)*secs
	mins_arc=(2*math.pi/60)*mins+secs_arc/60
	hours_arc=(2*math.pi/12)*hours+mins_arc/12

	-- Draw hour hand

	xh=xc+0.7*clock_r*math.sin(hours_arc)
	yh=yc-0.7*clock_r*math.cos(hours_arc)
	cairo_move_to(cr,xc,yc)
	cairo_line_to(cr,xh,yh)

	cairo_set_line_cap(cr,CAIRO_LINE_CAP_ROUND)
	cairo_set_line_width(cr,5)
	cairo_set_source_rgba(cr,rgb_to_r_g_b(clock_colour,clock_alpha))
	cairo_stroke(cr)
    

	-- Draw minute hand

	xm=xc+clock_r*math.sin(mins_arc)
	ym=yc-clock_r*math.cos(mins_arc)
	cairo_move_to(cr,xc,yc)
	cairo_line_to(cr,xm,ym)

	cairo_set_line_width(cr,3)
	cairo_stroke(cr)

	-- Draw seconds hand

	if show_seconds then
		xs=xc+clock_r*math.sin(secs_arc)
		ys=yc-clock_r*math.cos(secs_arc)
		cairo_move_to(cr,xc,yc)
		cairo_line_to(cr,xs,ys)

		cairo_set_line_width(cr,1)
		cairo_stroke(cr)
        
	end
end


function conky_clock_rings()
	local function setup_rings(cr,pt)
                local str=''
                local value=0

                str=string.format('${%s %s}',pt['name'],pt['arg'])
                str=conky_parse(str)

                value=tonumber(str)
                if value == nil then value = 0 end
                pct=value/pt['max']

                draw_ring(cr,pct,pt)
                
        end
    


	-- Check that Conky has been running for at least 5s

	if conky_window==nil then return end
	local cs=cairo_xlib_surface_create(conky_window.display,conky_window.drawable,conky_window.visual, conky_window.width,conky_window.height)

	local cr=cairo_create(cs)	
    cairo_surface_destroy(cs)

	local updates=conky_parse('${updates}')
	update_num=tonumber(updates)

	if update_num>5 then
		for i in pairs(settings_table) do
			setup_rings(cr,settings_table[i])
		end
	end

	draw_clock_hands(cr,clock_x,clock_y)
    
end

cairo_destroy(cr)

The weather script

#!/bin/sh
#AccuWeather (r) RSS weather tool for conky
#
#USAGE: weather.sh <locationcode>
#
#(c) Michael Seiler 2007
#
#ConkyColorsWeather logos
now=$(date)

hour=$(date +%H)

METRIC=1 #Should be 0 or 1; 0 for F, 1 for C

if [ -z $1 ]; then
    echo "Check LocCode" > ~/.conky/starwars/scripts/conkyweather.conf
    exit 1
fi

out=`curl --connect-timeout 30 -s http://rss.accuweather.com/rss/liveweather_rss.asp\?metric\=${METRIC}\&locCode\=$1 | perl -ne 'if (/Currently/) {chomp;/\<title\>Currently: (.*)?\<\/title\>/; print "$1"; }'`

echo "Currently: "$out | sed -n '/Currently:/ s/.*: \(.*\): \([0-9]*\)\([CF]\).*/\2°\3, \L\1/p' > ~/.conky/starwars/scripts/conkyweather.conf

cond=`echo $out | cut -d':' -f 1`

case "$cond" in

'Fog')
    echo -e "9"
;;
'Snow')
    echo -e "p"
;;
'Cloudy')
    echo -e "f"
;;
'Partly Cloudy')
    if [ $hour -lt 7 ]; then
	echo -e "C"
    elif [ $hour -lt 19 ]; then
	echo -e "c"
    else
	echo -e "C"
    fi
;;
'Intermittent Clouds')
     if [ $hour -lt 7 ]; then
	echo -e "C"
    elif [ $hour -lt 19 ]; then
	echo -e "b"
    else
	echo -e "C"
    fi
;;
'Mostly Cloudy')
    echo -e "e"
;;
'Mostly Cloudy W/ Showers')
    echo -e "h"
;;
'Mostly Cloudy W/ T-Storms')
    echo -e "l"
;;
'Sunny')
   echo -e "a"
;;
'Partly Sunny')
    echo -e "c"
;;
'Mostly Sunny')
    echo -e "b"
;;
'Partly Sunny W/ T-Storms')
    echo -e "k"
;;
'Thunderstorms')
   echo -e "l"
;;
'Rain')
    echo -e "h"
;;
'Showers')
     if [ $hour -lt 7 ]; then
	echo -e "G"
    elif [ $hour -lt 19 ]; then
	echo -e "g"
    else
	echo -e "G"
    fi
;;
'Frost')
    echo -e "r"
;;
'Clear')
    echo -e "A"
;;
'Mostly Clear')
    echo -e "C"
;;
*)
   echo -e  "E" && echo $now $out >> ~/.conky/starwars/scripts/errorlogo.txt
esac

exit 1

The weather script uses 2 files located in the scripts folder: conkyweather.conf (is used for the tekst after the weathericon) and errorlogo.txt (is used for complementing the cases in the weather script)


#131

If someone want a conky that show updates: Put this line at the bottom or where ever you want in your conkyrc.

${alignc 90}${font :size=15:bold}${color0}Updates${alignr 15}${color0}${execi 3600 checkupdates | wc -l} Updates

conkyupdate


#132

Official Manjaro i3 conky files (by @oberon) modified

Get the configurations at my Github page


#133

I can’t get this to work.
I’m using KDE Plasma, the background gets all black and I get this error:
conky: llua_do_call: function conky_clock_rings execution failed: …jack/.conky/conkies/config_lua/clock_rings_green.lua:300: attempt to perform arithmetic on local ‘value’ (a nil value)


#134

I have been trying to get this conky thing figured out. Im still a rookie to Linux, my 1st year is’nt up yet. Cant seem to get what Im looking for. @illuminati_RV sure has what I want… so, now gotta go to github and see If I can get it to work…Very nice @illuminati_RV


#135

This is SO good. Great job man!


#136

I cant get nothing to work either. I can have conky on desktop but I want to change the colors to match whatever wallpaper I use.