mirror of
https://github.com/eoli3n/dotfiles
synced 2024-11-26 14:13:53 +01:00
94 lines
3.4 KiB
Plaintext
94 lines
3.4 KiB
Plaintext
#!/usr/bin/conky
|
|
out_to_x no
|
|
own_window no
|
|
out_to_console yes
|
|
background no
|
|
max_text_width 0
|
|
|
|
# Update interval in seconds
|
|
update_interval 1.0
|
|
|
|
# This is the number of times Conky will update before quitting.
|
|
# Set to zero to run forever.
|
|
total_run_times 0
|
|
|
|
# Shortens units to a single character (kiB->k, GiB->G, etc.). Default is off.
|
|
short_units yes
|
|
|
|
# How strict should if_up be when testing an interface for being up?
|
|
# The value is one of up, link or address, to check for the interface
|
|
# being solely up, being up and having link or being up, having link
|
|
# and an assigned IP address.
|
|
if_up_strictness address
|
|
|
|
# Add spaces to keep things from moving about? This only affects certain objects.
|
|
# use_spacer should have an argument of left, right, or none
|
|
use_spacer right
|
|
|
|
# Force UTF8? note that UTF8 support required XFT
|
|
override_utf8_locale no
|
|
|
|
# number of cpu samples to average
|
|
# set to 1 to disable averaging
|
|
cpu_avg_samples 2
|
|
|
|
# Stuff after 'TEXT' will be formatted on screen
|
|
# JSON for i3bar
|
|
|
|
TEXT
|
|
|
|
[
|
|
|
|
#DOWN
|
|
|
|
#ADD DYNAMIC INTERFACE
|
|
|
|
{"full_text":" ${downspeed ${execi 120 ip r | grep default | head | cut -d\ -f5}}","color":"\#00AE58","separator":false,"separator_block_width":6, "min_width": 65, "align": "left"},\
|
|
|
|
#UP
|
|
|
|
#ADD DYNAMIC INTERFACE
|
|
|
|
{"full_text":" ${upspeed ${execi 120 ip r | grep default | head | cut -d\ -f5}}","color":"\#D0151E","separator":false,"separator_block_width":6, "min_width": 65, "align": "left"},\
|
|
|
|
#CPU
|
|
|
|
${if_match ${cpu cpu0} >= 80}\
|
|
{"full_text":" ${cpu cpu0}%","color":"\#D0151E","separator":false,"separator_block_width":6, "min_width": 65, "align": "left"},\
|
|
${else}
|
|
${if_match ${cpu cpu0} >= 50}\
|
|
{"full_text":" ${cpu cpu0}%","color":"\#E56C08","separator":false,"separator_block_width":6, "min_width": 65, "align": "left"},\
|
|
${else}
|
|
{"full_text":" ${cpu cpu0}%","color":"\#C5C5C5","separator":false,"separator_block_width":6, "min_width": 65, "align": "left"},\
|
|
$endif
|
|
$endif
|
|
|
|
#MEM
|
|
|
|
# CHANGE COLOR IN HIGH MEMORY USAGE
|
|
{"full_text":" ${mem}","color":"\#C5C5C5","separator":false,"separator_block_width":430, "min_width": 65, "align": "left"},\
|
|
|
|
#MPV
|
|
|
|
${if_match "${exec xdotool search --class mpv}"==""}\
|
|
{"full_text":" ","color":"\#00AE58","separator":false,"separator_block_width":6, "min_width": 570, "align": "right"},\
|
|
${else}
|
|
{"full_text": " ${exec xprop -id $(xdotool search --class mpv) | grep 'NET_WM_NAME(UTF8_STRING)' | cut -d'"' -f2} ","color":"\#C5C5C5","separator":false,"separator_block_width":6, "min_width":570 , "align": "right"},\
|
|
$endif
|
|
|
|
#MUSIC
|
|
|
|
${if_match "${exec mpc -f %artist% | head -n 1 | grep -v 'consume: off'| sed 's/\\n//g'}"==""}\
|
|
{"full_text":" ","color":"\#00AE58","separator":false,"separator_block_width":6, "min_width": 600, "align": "left"}\
|
|
${else}
|
|
${if_match "${exec mpc status | egrep 'paused|playing' | cut -d" " -f1}"=="[playing]"}\
|
|
{"full_text": " ${exec echo $(mpc -f "%artist%" | head -n 1 | head -c 40 | cut -d"%" -f1) - $(mpc -f "%title%" | head -n 1 | head -c 40 | cut -d"%" -f1)} ","color":"\#C5C5C5","separator":false,"separator_block_width":6, "min_width": 600, "align": "right"}\
|
|
${else}
|
|
{"full_text": " ${exec echo $(mpc -f "%artist%" | head -n 1 | head -c 40 | cut -d"%" -f1) - $(mpc -f "%title%" | head -n 1 | head -c 40 | cut -d"%" -f1)} ","color":"\#C5C5C5","separator":false,"separator_block_width":6,"min_width": 600, "align": "right"}\
|
|
$endif
|
|
#SEPARATOR
|
|
$endif
|
|
|
|
|
|
],
|