Il mio Conky

Questa pagina vuole avere la configurazione attuale di Conky che ho nel mio PC. Siccome ora sono arrivato a una configurazione soddisfacente la condivido con voi, ma l’idea è che se un domani mi stufassi e decidessi di cambiare la aggiungerei qua sotto (nel caso di miglioramenti mi limito ad aggiornare quella corrente).

Configurazione Conky attuale
-- v1.0
conky.config = {

-- false only for testing
background = false,

-- better fonts
use_xft = true,

-- update interval
update_interval = 1.5,
total_run_times = 0,

-- window settings (trasparence enabled)
own_window = true,
own_window_transparent = true,
own_window_type = 'normal',
own_window_class = 'semi-conky',
own_window_hints = 'undecorated,below,sticky,skip_taskbar,skip_pager',
own_window_argb_visual = true,
own_window_argb_value = 255,

-- anti-flickering
double_buffer = true,

-- size
minimum_width = 400,
minimum_height = 1000,
maximum_width = 400,

-- shadows
draw_shades = false,

-- position
alignment = 'top_right',
gap_x = 3,
gap_y = 40,

-- borders
draw_outline = false,
default_outline_color = 'red',
draw_graph_borders = true,

-- frame
draw_borders = false,

-- color
default_color = 'white',

show_graph_range = false,
show_graph_scale = false,
--default_bar_height = 6,
--default_bar_width = 200,
text_buffer_size = 1000,
override_utf8_locale = true,

font = 'Liberation Mono:size=9', --important for shades
template0 = 'Liberation Mono:size=9',
template1 = 'Liberation Sans:size=12',
template2 = 'Liberation Sans:size=10',
template3 = 'Liberation Sans:size=5',

}
conky.text= [[

${font $template1}${color 0066FF}Information ${hr 2}${color lightgray}${font $template0}
${goto 20}Kernel: ${alignr}Linux ${kernel} on ${machine}
${goto 20}Operating System: ${alignr}Arch Linux
${goto 20}Total Uptime: ${alignr}${uptime_short}
${goto 20}Battery:${alignr}${battery_percent BAT0}%

${font $template1}${color 0066FF}Processor${hr 2}${font $template0}${color lightgray}
${goto 20}CPU Model: ${alignr}${execi 100 lscpu | grep -i "model name" | cut -c 30-}
${goto 20}Temperature: ${alignr}${execi 15 sensors | grep -i "CPU" | cut -c 18-24}

${goto 20}${color lightgray}CPU 1 | ${cpu cpu1}% | ${freq_g 1} Ghz${alignr}CPU 2 | ${cpu cpu2}% | ${freq_g 2} Ghz${color 0066FF}
${goto 20}${cpugraph cpu1 32, 180 FFFFFF 0066FF}${alignr}${cpugraph cpu2 32, 180 FFFFFF 0066FF}
${goto 20}${color lightgray}CPU 3 | ${cpu cpu3}% | ${freq_g 3} Ghz${alignr}CPU 4 | ${cpu cpu4}% | ${freq_g 4} Ghz${color 0066FF}
${goto 20}${cpugraph cpu3 32, 180 FFFFFF 0066FF}${alignr}${cpugraph cpu4 32, 180 FFFFFF 0066FF}
${goto 20}${color lightgray}CPU 5 | ${cpu cpu5}% | ${freq_g 5} Ghz${alignr}CPU 6 | ${cpu cpu6}% | ${freq_g 6} Ghz${color #0066FF}
${goto 20}${cpugraph cpu5 32, 180 FFFFFF 0066FF}${alignr}${cpugraph cpu6 32, 180 FFFFFF 0066FF}
${goto 20}${color lightgray}CPU 7 | ${cpu cpu7}% | ${freq_g 7} Ghz${alignr}CPU 8 | ${cpu cpu8}% | ${freq_g 8} Ghz${color #0066FF}
${goto 20}${cpugraph cpu7 32, 180 FFFFFF 0066FF}${alignr}${cpugraph cpu8 32, 180 FFFFFF 0066FF}

${font $template1}${color 0066FF}Memory${hr 2}${font $template0}${color lightgray}
${goto 20}$mem / $memmax ${alignr} $memperc%
${goto 20}${color 0066FF}${membar 8, 380}${color lightgray}

${font $template1}${color 0066FF}Discrete GPU ${hr 2}${font $template0}${color lightgray}
${if_match ${exec lsmod | grep 'nvidia' -c} > 0}\
${color #FCAF3E}
${exec nvidia-smi --query-gpu=name --format=csv,noheader}${color lightgray}
Temperature: ${alignr}${color #FCAF3E}${exec nvidia-smi --query-gpu=temperature.gpu --format=csv,noheader,nounits} °C ${color lightgray}
Memory:${alignr}${exec nvidia-smi --query-gpu=memory.used --format=csv,noheader} / ${exec nvidia-smi --query-gpu=memory.total --format=csv,noheader}
Load: ${alignr}${exec nvidia-smi --query-gpu=utilization.gpu --format=csv,noheader}
${else}\
${goto 20}OFF
${endif}\

${font $template1}${color 0066FF}Hard Drive${hr 2}${font $template0}${color lightgray}
${goto 20}/${alignr}${fs_size /}
${goto 20}${color 0066FF}${fs_bar /}${color lightgray}
${goto 20}${fs_used_perc /}%${alignr}${fs_used /}${font $template3}

${goto 20}${font $template0}/home${alignr}${fs_size /home}
${goto 20}${color 0066FF}${fs_bar /home}${color lightgray}
${goto 20}${fs_used_perc /home}%${alignr}${fs_used /home}${font $template2}
${goto 20}${color 0066FF}${diskiograph_read sda 32, 190 FFFFFF 0066FF}${alignr}${diskiograph_write sda 32, 190 FFFFFF 0066FF}${color lightgray}
${goto 20}SSD Read: ${diskio_read sda}${alignr} SSD Write: ${diskio_write sda}
${goto 20}${color 0066FF}${diskiograph_read sdb 32, 190 FFFFFF 0066FF}${alignr}${diskiograph_write sdb 32, 190 FFFFFF 0066FF}${color lightgray}
${goto 20}HDD Read: ${diskio_read sdb}${alignr} HDD Write: ${diskio_write sdb}

${font $template1}${color 0066FF}Network${hr 2}${font $template0}${color lightgray}
${if_existing /sys/class/net/wlan0/operstate up}${alignc}${font $template2}${color FFFFFF}Wireless
${goto 20}${font $template0}${color lightgray}Address: ${alignr} ${addr wlan0}
${goto 20}Connected to: ${alignr} $wireless_essid
${goto 20}${color 0066FF}${upspeedgraph wlan0 32, 180 FFFFFF 0066FF}${alignr}${downspeedgraph wlan0 32, 180 FFFFFF 0066FF}${color lightgray}
${goto 20}Upload speed: ${upspeed wlan0}${alignr}Download speed: ${downspeed wlan0}${endif}
${if_existing /sys/class/net/enp3s0f1/operstate up}${font $template2}${color FFFFFF}${alignc}Ethernet
${goto 20}${font $template0}${color lightgray}Address: ${alignr} ${addr enp3s0f1}
${goto 20}Up: ${upspeed enp3s0f1}${alignr}Down: ${downspeed enp3s0f1}${endif}
${if_existing /sys/class/net/wlan0/operstate down}${if_existing /sys/class/net/enp3s0f1/operstate down} ${alignc}${font $template2}${color FFFFFF}Not Connected ${endif}${endif}
]];