hello siamhie
Looking for an "if" to make zero config live conky cpu cores.
Beyond two cores I cannot test.
Can machines with multi cores please try this
sample conky, searching for if core_count.
try this sample
Looking for a cpu "if" for automatic.
update: Change code in revised conky.text
There is a processor with 44 cores. wow.
Code: Select all
conky.config = {
total_run_times = 114,
own_window = true,
own_window_type = 'normal',
own_window_hints = 'sticky,undecorated',
alignment = 'br',
gap_x = 95,
gap_y = 85,
minimum_width = 136,
default_color = 'ivory',
-- use_xft = true,
-- xftalpha = 1.0,
-- font = 'Liberation Serif',
double_buffer = true
};
conky.text = [[
$nodename ${if_match "48"<="${exec grep cpu /proc/stat |sort -V -r |head -n 1|cut -du -f2|cut -d" " -f1}"}${cpugraph cpu48 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu47 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu46 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu45 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "44"<="${exec grep cpu /proc/stat |sort -V -r |head -n 1|cut -du -f2|cut -d" " -f1}"}${cpugraph cpu44 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu43 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu42 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu41 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu40 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu39 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu38 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu37 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "36"<="${exec grep cpu /proc/stat |sort -V -r |head -n 1|cut -du -f2|cut -d" " -f1}"}${cpugraph cpu36 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu35 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu34 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu33 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "32"<="${exec grep cpu /proc/stat |sort -V -r |head -n 1|cut -du -f2|cut -d" " -f1}"}${cpugraph cpu32 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu31 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu30 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu29 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu28 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu27 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu26 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu25 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "24"<="${exec grep cpu /proc/stat |sort -V -r |head -n 1|cut -du -f2|cut -d" " -f1}"}${cpugraph cpu24 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu23 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu22 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu21 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "20"<="${exec grep cpu /proc/stat |sort -V -r |head -n 1|cut -du -f2|cut -d" " -f1}"}${cpugraph cpu20 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu19 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "18"<="${exec grep cpu /proc/stat |sort -V -r |head -n 1|cut -du -f2|cut -d" " -f1}"}${cpugraph cpu18 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu17 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "16"<="${exec grep cpu /proc/stat |sort -V -r |head -n 1|cut -du -f2|cut -d" " -f1}"}${cpugraph cpu16 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu15 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "14"<="${exec grep cpu /proc/stat |sort -V -r |head -n 1|cut -du -f2|cut -d" " -f1}"}${cpugraph cpu14 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu13 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "12"<="${exec grep cpu /proc/stat |sort -V -r |head -n 1|cut -du -f2|cut -d" " -f1}"}${cpugraph cpu12 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu11 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "10"<="${exec grep cpu /proc/stat |sort -V -r |head -n 1|cut -du -f2|cut -d" " -f1}"}${cpugraph cpu10 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu9 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "8"<="${exec grep cpu /proc/stat |sort -V -r |head -n 1|cut -du -f2|cut -d" " -f1}"}${cpugraph cpu8 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu7 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "6"<="${exec nproc}"}${cpugraph cpu6 32,17 5599cc 5599cc 0.87 -l}${cpugraph cpu5 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "4"<="${exec nproc}"}${cpugraph cpu4 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "3"<="${exec nproc}"}${cpugraph cpu3 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match "2"<="${exec nproc}"}${cpugraph cpu2 32,17 5599cc 5599cc 0.87 -l}${endif} ${if_match 1!=${exec nproc}}${cpugraph cpu1 32,17 5599cc 5599cc 0.93 -l}${endif} ${cpugraph cpu0 30,170 5599cc 5599cc}
]]