/ Linux

Conkyrc

J'ai récemment un peu tweaké mon fichier de configuration conky, j'en profite donc pour le partager avec vous ici. Pour qu'il fonctionne correctement, il faut installer les paquets suivants :

  • lm_sensors
  • conky-nvidia
  • conky-colors
  • Un driver Nvidia pour avoir les commandes nvidia-smi & nvidia-settings

Il faudra bien entendu adapter pour un GPU d'une marque différente.

Voilà mon conky :
Conky

.conkyrc :

######################
# - Conky settings - #
######################
update_interval 10
total_run_times 0
net_avg_samples 2
cpu_avg_samples 2

imlib_cache_size 0
double_buffer yes
# no_buffers yes

#####################
# - Text settings - #
#####################
use_xft yes
xftfont Ubuntu:size=10
override_utf8_locale yes
text_buffer_size 2048

#############################
# - 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 200

alignment top_left
gap_x 1950
gap_y 20
minimum_size 220 1000
maximum_width 220

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

color0 white
color1 E07A1F
color2 white

TEXT
SYSTEM ${hr 2}
${goto 6}${voffset 6}${font conkycolorslogos:size=32}a${font}${goto 55}${voffset -25}$machine
${goto 55}Kernel: ${kernel}

${font Arial Black:size=22}${alignc}${time %H:%M}${font}
${alignc}${time %A, %B %d, %Y}

CPU ${hr 2}
${goto 45}${color #53D5F6}${execi 30grep 'model name' /proc/cpuinfo | sed -e 's/model name.*: //'| uniq | cut -c 1-26} $color
${goto 6}${voffset 4}${font conkycolors:size=16}d${font}${voffset -4}${goto 32}Frequency: ${alignr}${freq_g (1)} GHz
${goto 6}${voffset 4}${font conkycolors:size=16}l${font}${voffset -4}${goto 32}CPU1: ${cpu cpu1}%${alignr}CPU2: ${cpu cpu2}%
${goto 6}${voffset 4}${font conkycolors:size=16}l${font}${voffset -4}${goto 32}CPU3: ${cpu cpu3}%${alignr}CPU4: ${cpu cpu4}%
${goto 6}${voffset 4}${font conkycolors:size=16}l${font}${voffset -4}${goto 32}CPU5: ${cpu cpu5}%${alignr}CPU6: ${cpu cpu6}%
${goto 6}${voffset 4}${font conkycolors:size=16}l${font}${voffset -4}${goto 32}CPU7: ${cpu cpu7}%${alignr}CPU8: ${cpu cpu8}%

CPU Temperatures ${hr 2}
${goto 6}${voffset 4}${font conkycolors:size=16}8${font}${voffset -4}${goto 32}Core0:${alignr}${color #FCAF3E}${execi 30 sensors | grep 'Core 0' | awk '{print $3}' | sed 's/+//' | sed 's/\.0//g'} $color
${goto 6}${voffset 4}${font conkycolors:size=16}8${font}${voffset -4}${goto 32}Core1:${alignr}${color #FCAF3E}${execi 30 sensors | grep 'Core 1' | awk '{print $3}' | sed 's/+//' | sed 's/\.0//g'} $color
${goto 6}${voffset 4}${font conkycolors:size=16}8${font}${voffset -4}${goto 32}Core2:${alignr}${color #FCAF3E}${execi 30 sensors | grep 'Core 2' | awk '{print $3}' | sed 's/+//' | sed 's/\.0//g'} $color
${goto 6}${voffset 4}${font conkycolors:size=16}8${font}${voffset -4}${goto 32}Core3:${alignr}${color #FCAF3E}${execi 30 sensors | grep 'Core 3' | awk '{print $3}' | sed 's/+//' | sed 's/\.0//g'} $color

GPU ${hr 2}
${goto 6}${voffset 4}${font conkycolorslogos:size=16}n${font}${voffset -4}${goto 32}${exec nvidia-smi --query-gpu=name --format=csv,noheader}${alignr}${color #FCAF3E}${exec nvidia-smi --query-gpu=driver_version --format=csv,noheader} $color
${goto 6}${voffset 4}${font conkycolors:size=16}8${font}${voffset -4}${goto 32}Temperature: ${alignr}${color #FCAF3E}${exec nvidia-settings -q GPUCoreTemp | grep Attribute | cut -d ' ' -f 6 | cut -c 1-2} °C$color
${goto 6}${voffset 4}${font conkycolors:size=16}e${font}${voffset -4}${goto 32}Memory:${alignr}${exec nvidia-smi --query-gpu=memory.used --format=csv,noheader} / ${exec nvidia-smi --query-gpu=memory.total --format=csv,noheader}

General ${hr 2}
${goto 6}${voffset 4}${font conkycolors:size=16}g${font}${voffset -4}${goto 32}Mem: ${mem} ${alignr}${membar 8,60}
${goto 6}${voffset 4}${font conkycolors:size=16}i${font}${voffset -4}${goto 32}Disk: ${diskio}${alignr}${diskiograph 8,60 F57900 FCAF3E}
${goto 6}${voffset 4}${font conkycolors:size=16}i${font}${voffset -4}${goto 32}Swap: $swapperc% ${alignr}${swapbar 8,60}
${goto 6}${voffset 4}${font conkycolors:size=16}o${font}${voffset -4}${goto 32}Uptime: ${alignr}${uptime}
${goto 6}${voffset 4}${font conkycolors:size=16}C${font}${voffset -4}${goto 32}Processes: ${alignr}$processes ($running_processes running)
${voffset 4}${goto 32}Threads: ${alignr}$threads ($running_threads running)

${goto 7.5}${voffset 4}${font Poky:size=15}a${font}${goto 32}${voffset -10}Highest: ${alignr 13}CPU${alignr}RAM
${goto 32}${voffset -5.5}${hr 1}
${voffset -1}${goto 32}${top name 1} ${goto 152}${top cpu 1}${alignr }${top mem 1}
${voffset -1}${goto 32}${top name 2} ${goto 152}${top cpu 2}${alignr }${top mem 2}
${voffset -1}${goto 32}${top name 3} ${goto 152}${top cpu 3}${alignr }${top mem 3}
${voffset -1}${goto 32}${top name 4} ${goto 152}${top cpu 4}${alignr }${top mem 4}
${voffset -1}${goto 32}${top name 5} ${goto 152}${top cpu 5}${alignr }${top mem 5}

HDD ${hr 2}
${voffset 1}
${font conkycolors:size=15}i${font}${voffset -5}${goto 32}HDD Temp:${alignr}${color #FCAF3E}${exec sudo hddtemp /dev/sda -n --unit=C} °C$color
${voffset 1}
${font conkycolors:size=16}i${font}${voffset -5}${goto 32}File System
${voffset 4}${fs_free /}/${fs_size /} ${alignr}${fs_bar 8,60 /}
${voffset 1}
${font conkycolors:size=16}i${font} ${voffset -5}Home
${voffset 4}${fs_free /home}/${fs_size /home} ${alignr}${fs_bar 8,60 /home}

Network ${hr 2}
${voffset 0.1}
${if_up eno1}
${voffset -13}${font conkycolors:size=14}x${font}${goto 32}${voffset -6}Up: ${upspeed eno1}${font} ${alignr}${upspeedgraph eno1 8,60 F57900 FCAF3E}
${goto 32}Total: ${totalup eno1}
${voffset 1}
${voffset -2}${font conkycolors:size=14}w${font}${goto 32}${voffset -6}Down: ${downspeed eno1}${font} ${alignr}${downspeedgraph eno1 8,60 F57900 FCAF3E}
${goto 32}Total: ${totaldown eno1}
${voffset 1}
# ${voffset -2}${font conkycolors:size=13}A${font}${goto 32}${voffset -4}Local IP: ${alignr}${addr eno1}
${endif}

Disponible aussi sur Github : > ici <

Conkyrc
Share this