-
Notifications
You must be signed in to change notification settings - Fork 7
/
conky.conf
208 lines (169 loc) · 6.88 KB
/
conky.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
-- vim: ts=4 sw=4 noet ai cindent syntax=lua
--[[
Conky, a system monitor, based on torsmo
Any original torsmo code is licensed under the BSD license
All code written since the fork of torsmo is licensed under the GPL
Please see COPYING for details
Copyright (c) 2004, Hannu Saransaari and Lauri Hakkarainen
Copyright (c) 2005-2012 Brenden Matthews, Philip Kovacs, et. al. (see AUTHORS)
All rights reserved.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
]]
local _dirname_ = debug.getinfo(1, "S").source:sub(2):match("(.*[/\\])")
conky.config = {
--Various settings
background = true,
xinerama_head = 0,
cpu_avg_samples = 2,
diskio_avg_samples = 10,
double_buffer = true,
if_up_strictness = 'address',
net_avg_samples = 2,
no_buffers = true,
temperature_unit = 'celsius',
update_interval = 1,
imlib_cache_size = 0,
cpu_avg_samples = 2,
no_buffers = true,
out_to_console = false,
out_to_stderr = false,
extra_newline = false,
own_window = true,
stippled_borders = 0,
update_interval = 1.0,
uppercase = false,
use_spacer = 'none',
-- Placement
alignment = 'top_right',
gap_x = 20, -- 160
gap_y = 30,
minimum_width = 350,
maximum_width = 350,
--Graphical
border_inner_margin = 10,
border_outer_margin = 10,
draw_borders = false,
draw_graph_borders = true,
draw_shades = false,
draw_outline = false,
show_graph_scale = false,
show_graph_range = false,
own_window_argb_visual = true,
own_window_transparent = false,
own_window_argb_value = 170,
own_window_colour = '1a1b26',
own_window_type = 'override', -- options are: normal/override/dock/desktop/panel, --desktop for bspwm
own_window_class = 'Conky',
own_window_hints = 'undecorated,below,skip_taskbar,sticky,skip_pager' ,
-- Text
-- text
font = 'JetBrains Mono:size=10',
format_human_readable = true,
use_xft = true,
max_text_width = 0,
short_units = true,
xftalpha = 1,
override_utf8_locale = true,
-- Colors
default_color = 'a2a8ba',
default_outline_color = 'white',
default_shade_color = 'white',
-- md blue (200)
color1 = '81a1c1', -- title color
-- md blue (200)
color3 = '81a1c1', -- text color
-- md dark blue (200 -> dark)
color4 = '81a1c1' , -- accent color
color5 = 'f06a2b', -- graph color
}
conky.text = [[
${font :size=36}${color1}${alignc}${time %H:%M}
${font}${color}${voffset -20}${alignc}${time %A %d %B %Y}
${color3}${hr 2}
${color3}Uptime: ${alignr}${color}$uptime_short
${color3}Boot Time: ${color}${alignr}${execi -1 systemd-analyze | grep -o -P '.{0,0}=.{2,5}' | cut -c 2-6 }s
${color3}Kernel: ${alignr}${color}${kernel}
${color3}Distro: ${alignr}${color}${execi 6000 lsb_release -d | grep 'Descr'|awk {'print $2 " " $3" " $4"" $5'}}
#------------+
#TEMPS
#------------+
${font}${color1}TEMPS ${hr 2}
${voffset 5}${color}${font}${color3}CPU: ${alignr}$color${execi 5 sensors | grep Tccd1: | cut -c 16-19}°C
${color3}GPU: ${alignr}$color${execi 60 nvidia-smi --query-gpu=temperature.gpu --format=csv,noheader }°C
#${color}${color3}SSD:${alignr}${color}${execi 5 hddtemp /dev/sda | cut -d ":" -f 3}
#------------+
#CPU
#------------+
${font}${color1}PROCESSOR ${hr 2}
${voffset 5}${font}${color3}Name: $color$alignr${execi 6000 cat /proc/cpuinfo | grep 'model name' | sed -e 's/model name.*: //'| uniq | cut -c 1-16}
${color3}Freq: ${alignr}$color${freq_g} GHz
${color3}Usage: ${alignr}$color${cpu}%
${color4}${cpugraph cpu }
${font}${color1}GPU ${hr 2}
${color3}Name: ${alignr}${color}${exec nvidia-smi --query-gpu=gpu_name --format=csv,noheader,nounits} $color
#${color3}Temperature ${alignr}${color} ${execi 60 nvidia-settings -query [gpu:0]/GPUCoreTemp -t} °C
#${color3}Usage: ${alignr}${color} ${exec nvidia-smi | grep % | cut -c 61-63} %
${color3}VRAM ${alignr}${color} ${exec nvidia-smi | grep % | cut -c 36-40} MB
#${color3}Power ${alignr} ${color} ${exec nvidia-smi | grep % | cut -c 21-23} W
#------------+
#PROCESSES
#------------+
${font}${color1}PROCESS ${hr 2}
${voffset 5}${color3}Name${alignr}CPU%
$color4${top name 1}$alignr${top cpu 1}$color
${top name 2} ${alignr}${top cpu 2}
${top name 3} ${alignr}${top cpu 3}
${color3}Processes: ${alignr}${color}${processes} (${running_processes})
${color3}Threads: ${alignr}${color}${threads} (${running_threads})
#------------+
#MEMORY
#------------+
${font}${color1}MEMORY ${hr 2}
${voffset 5}${font}${color3}Used: ${color}${mem} ($memperc%)${color3}${alignr}Free: ${color}${memeasyfree}
${color4}${membar}
#------------+
#NETWORK
#------------+
${font}${color1}NETWORK ${hr 2}
${if_existing /sys/class/net/enp5s0/operstate up}
${voffset 5}${font}${color3}${addr enp5s0}${alignr}${font}${color}
${color3}Established: ${goto 345}${color}${execi 5 netstat -ntpe | grep -v '127.0.0.1'| grep -iE 'established' | wc -l}
${color3}Down: ${color}${downspeed enp5s0}/s ${color3}${alignr} Total: ${color}${totaldown enp5s0}
${color4}${downspeedgraph enp5s0}${color}
${endif}
${color3}Up: ${color}${upspeed enp5s0}/s ${color3}${alignr} Total: ${color}${totalup enp5s0}
${color4}${upspeedgraph enp5s0 }${color}
${color1}FS ${hr 2}
${if_existing /dev/nvme0n1}
${voffset 5}${color1}/:${alignr}${color}${fs_used /} / ${fs_size /}
${color4}${fs_bar /}
${color1}Read: ${alignr}${color}${diskio_read /dev/nvme0n1}
${color1}${diskiograph_read /dev/nvme0n1 }
${color1}Write: ${alignr}${color}${diskio_write /dev/nvme0n1}
${color1}${diskiograph_write /dev/nvme0n1 }
${endif}
${voffset 5}${color1}/dev/sda6:${alignr}${color}${fs_used /run/media/madhur/centos} / ${fs_size /run/media/madhur/centos}
${color4}${fs_bar /run/media/madhur/centos}
${color1}Read: ${alignr}${color3}${diskio_read /dev/sda}
${color1}${diskiograph_read /dev/sda }
${color1}Write: ${alignr}${color3}${diskio_write /dev/sda}
${color1}${diskiograph_write /dev/sda }
${voffset 5}${color1}/dev/sdb1:${alignr}${color}${fs_used /data} / ${fs_size /data}
${color4}${fs_bar /data}
${color1}Read: ${alignr}${color3}${diskio_read /dev/sdb}
${color1}${diskiograph_read /dev/sdb }
${color1}Write: ${alignr}${color3}${diskio_write /dev/sdb}
${color1}${diskiograph_write /dev/sdb }
${color1}Failed Units ${hr 2}
${color5} ${exec chronic systemctl --failed}
${color5} ${exec chronic systemctl --failed --user}
]]