Conky 窗口大小不适合输出

Conky 窗口大小不适合输出

我正在使用以下 conky 脚本,它运行良好……直到我删除第 43 行和/或第 44 行的注释 - 这在我的 conky 窗口中绘制了一个电池图标。我的问题是,如何启用此新功能而不在窗口底部创建空白区域?

版本信息:
- Conky 1.9.0 于 2013 年 5 月 10 日星期五 23:14:51 UTC 针对 Linux 3.2.0-37-generic (i686) 编译
- XUbuntu 13.10 (32 位)

# --------------------------------------------------------------------------------------------------------------------------------------------------------------- .conkyrc
# Purpose:    Conky Configuration File
# Requires:   sudo apt-get install cpufrequtils lm-sensors && sudo sensors-detect && sudo service kmod start
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈

  alignment                   middle_right                  # Display on right edge of screen, vertically centered
  background                  yes                           # Fork to background
  cpu_avg_samples             3                             # Sample and average CPU cores three times
  default_bar_size            208 10                        # Set bar height
  default_color               gold                          # Set default text color to gold
  double_buffer               yes                           # Enable double buffering to eliminate flicker
  gap_x                       6                             # Offset horizontal placement to allow a one pixel gap between window and screen edge
  gap_y                       0                             # Make conky respect the vertical centering
  if_up_strictness            link                          # An ethernet connection is only considered to be up if there's an active link
  maximum_width               297                           # Set width - 307px
  max_user_text               24576                         # Maximum size of user text buffer (layout below TEXT line in config file) - Default is 16384 bytes
  minimum_size                297                           # Set width - 307px
  net_avg_samples             3                             # Sample and average network activity three times
  no_buffers                  yes                           # Disregard file system buffers when calculating memory usage
  own_window                  yes                           # Required to minimize double buffer size
  own_window_argb_value       191                           # Set conky background opacity (0 transparent, 63-127-191 25-50-75% translucent, 255 opaque)
  own_window_argb_visual      yes                           # Enable ARGB settings
  own_window_hints            undecorated                   # No window decorations
  own_window_hints            below                         # Always visible as a desktop element
  own_window_hints            sticky                        # Sticky across workspaces
  own_window_hints            skip_taskbar                  # Do not display to taskbar
  own_window_hints            skip_pager                    # Do not display to other application switchers
  pad_percents                3                             # Stabilize layout
  temperature_unit            celsius                       # Show temperatures in Celsius
  top_name_width              20                            # Set top name width
  update_interval             0.5                           # Set update speed
  use_spacer                  left                          # Stabilize layout
  use_xft                     yes                           # Employ XFT anti-aliased fonts
  xftfont                     DejaVu Sans Mono:size=9       # Select an appropriate font and size
# default_bar_size            192 12                        # Set bar height
# top_name_width              15                            # Set top name width
# xftfont                     DejaVu Sans Mono:size=10      # Select an appropriate font and size

TEXT
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈ Header
${voffset -6}${alignc}${color green}${exec whoami}@${nodename}
${voffset -15}${if_match "${battery_short}" == "C"}${color yellow}${endif}${if_match "${battery_short}" == "D"}${color red}${endif}${if_match "${battery_short}" == "U"}${color white}${endif}
#ISSUE HERE: ${voffset -13}${alignr 5}${battery_bar 10,35}
#ISSUE HERE: ${voffset -15}${alignr 2}${entropy_bar 4,3}${voffset -2}
${voffset -2}${alignc}${color lightblue}${exec cat /etc/*release | grep "PRETTY_NAME" | cut -c13-100 | cut -d '"' -f 2} (${if_match "${machine}" == "i686"}32${else}64${endif}-bit)
${voffset -7}${color cyan}${hr}
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
#
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈ Calendar and Clock
${voffset -6} ${execi 60 cal -h | head --lines=1}
${color black}${execpi 60 calendar=`date +%_d`; cal -h | sed '1d' | sed '/./!d' | sed 's/$/ /' | fold -w 21 | sed -n '/^.\{21\}/p' | sed 's/^/ /' | sed /" ${calendar} "/s/" ${calendar} "/" "''"${calendar}"'${color black}'" "/}
${voffset -106}${offset -1}${color purple}${execpi 60 calendar=`date +%_d`; cal -h | sed '1d' | sed '/./!d' | sed 's/$/ /' | fold -w 21 | sed -n '/^.\{21\}/p' | sed 's/^/ /' | sed /" ${calendar} "/s/" ${calendar} "/" "'${color green}'"${calendar}"'${color purple}'" "/}
${voffset -119}${alignr} ------------------- 
${alignr} ------------------- 
${alignr} ------------------- 
${alignr} ------------------- 
${alignr} ------------------- 
${alignr} ------------------- 
${alignr}${color purple} --- ${color}${time %r}${color purple} --- 
${voffset -10}${color cyan}${stippled_hr}
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
#
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈ System specs
${voffset -5}${color purple}Uptime:${alignr}${color}${uptime}
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
#
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈ CPU monitoring
${voffset 6}${color purple}CPU:   ${color white}${if_match ${hwmon 1 temp 2} >= 50}${color cyan}${endif}${if_match ${hwmon 1 temp 2} >= 60}${color green}${endif}${if_match ${hwmon 1 temp 2} >= 70}${exec aplay ~/alarm.wav}${color}${endif}${if_match ${hwmon 1 temp 2} >= 80}${color orange}${endif}${if_match ${hwmon 1 temp 2} >= 90}${color red}${endif}${if_match ${hwmon 1 temp 2} >= 95}${blink ${hwmon 1 temp 2}°C}${else}${hwmon 1 temp 2}°C${endif}${alignr}${color lightblue}${exec cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor} ${color lightblue}@ ${freq_g 0}GHz
${if_existing /sys/devices/system/cpu/cpu0}${color purple} Core 1:${color}${cpu cpu1}% ${if_match ${cpu cpu1} < 25}${color green}${endif}${if_match ${cpu cpu1} > 75}${color red}${endif}${cpubar cpu1}
${endif}${if_existing /sys/devices/system/cpu/cpu1}${voffset -2}${color purple} Core 2:${color}${cpu cpu2}% ${if_match ${cpu cpu2} < 25}${color green}${endif}${if_match ${cpu cpu2} > 75}${color red}${endif}${cpubar cpu2}
${endif}${if_existing /sys/devices/system/cpu/cpu2}${voffset -2}${color purple} Core 3:${color}${cpu cpu3}% ${if_match ${cpu cpu3} < 25}${color green}${endif}${if_match ${cpu cpu3} > 75}${color red}${endif}${cpubar cpu3}
${endif}${if_existing /sys/devices/system/cpu/cpu3}${voffset -2}${color purple} Core 4:${color}${cpu cpu4}% ${if_match ${cpu cpu4} < 25}${color green}${endif}${if_match ${cpu cpu4} > 75}${color red}${endif}${cpubar cpu4}
${endif}${if_existing /sys/devices/system/cpu/cpu4}${voffset -2}${color purple} Core 5:${color}${cpu cpu5}% ${if_match ${cpu cpu5} < 25}${color green}${endif}${if_match ${cpu cpu5} > 75}${color red}${endif}${cpubar cpu5}
${endif}${if_existing /sys/devices/system/cpu/cpu5}${voffset -2}${color purple} Core 6:${color}${cpu cpu6}% ${if_match ${cpu cpu6} < 25}${color green}${endif}${if_match ${cpu cpu6} > 75}${color red}${endif}${cpubar cpu6}
${endif}${if_existing /sys/devices/system/cpu/cpu6}${voffset -2}${color purple} Core 7:${color}${cpu cpu7}% ${if_match ${cpu cpu7} < 25}${color green}${endif}${if_match ${cpu cpu7} > 75}${color red}${endif}${cpubar cpu7}
${endif}${if_existing /sys/devices/system/cpu/cpu7}${voffset -2}${color purple} Core 8:${color}${cpu cpu8}% ${if_match ${cpu cpu8} < 25}${color green}${endif}${if_match ${cpu cpu8} > 75}${color red}${endif}${cpubar cpu8}${endif}
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
#
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈ RAM monitoring
${voffset 6}${color purple}RAM:    ${color}${memperc}% ${if_match ${memperc} < 25}${color green}${endif}${if_match ${memperc} > 75}${color red}${endif}${membar}
${voffset -1}${color purple} Used:${color}${alignr 31}${mem}   ${color purple}Total: ${color}${alignr}${memmax} 
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
#
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈ Filesystem monitoring
${voffset 6}${color purple}Home:   ${color}${fs_used_perc /home}% ${if_match ${fs_used_perc /home} < 25}${color green}${endif}${if_match ${fs_used_perc /home} > 75}${color red}${endif}${fs_bar /home}
${voffset -1}${color purple} Used:${color}${alignr 31}${fs_used /home}   ${color purple}Total: ${color}${alignr}${fs_size /home} 
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
#
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈ Wired Network Status
${voffset 6}${color purple}LAN: ${alignr}${if_up eth0}${color cyan}Connected
 ${voffset -1}${color purple}MAC Address: ${alignr}${color}${execi 1800 ifconfig eth0 | grep eth0 | cut -c39-55 | awk '{ print toupper($1) }'} 
 ${voffset -2}${color purple}L: ${alignr 157}${color}${addr eth0}
 ${voffset -15}${color purple}                      R: ${alignr}${color}${execi 1800 curl -s http://checkip.dyndns.org/ | cut -d : -f 2- | cut -d \< -f -1 | sed 's/[^0-9.]*//g'} 
 ${voffset -2}${color purple}↑:${color}${alignr 157}${upspeedf eth0} KiB/s
 ${voffset -15}${color purple}                      ↓:${alignr}${color}${downspeedf eth0} KiB/s ${else}${color red}Offline${endif}
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
#
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈ Wireless Status
${voffset 6}${color purple}WiFi: ${color}${if_up wlan0}${if_match "  unk" == "${wireless_link_qual_perc wlan0}"}${alignr}${color white}Broadcast${else}${wireless_link_qual_perc wlan0}% ${color red}${if_match ${wireless_link_qual_perc wlan0} > 33}${color}${endif}${if_match ${wireless_link_qual_perc wlan0} > 67}${color green}${endif}${wireless_link_bar wlan0}${endif}
 ${voffset -1}${color purple}SSID: ${alignr}${color}${wireless_essid wlan0} 
 ${voffset -2}${color purple}MAC Address:  ${alignr}${color}${wireless_ap wlan0} 
 ${voffset -2}${color purple}L: ${alignr 157}${color}${addr wlan0}
 ${voffset -15}${color purple}                      R: ${alignr}${color}${if_match "  unk" == "${wireless_link_qual_perc wlan0}"}N/A${else}${execi 1800 curl -s http://checkip.dyndns.org/ | cut -d : -f 2- | cut -d \< -f -1 | sed 's/[^0-9.]*//g'}${endif} 
 ${voffset -2}${color purple}↑:${color}${alignr 157}${upspeedf wlan0} KiB/s
 ${voffset -15}${color purple}                      ↓:${color}${alignr}${downspeedf wlan0} KiB/s${else}${alignr}0% ${color red}${execbar echo 0}
${voffset -17}${alignr -1}${blink ----------------------------}${endif} 
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
#
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈ Networking
${if_gw}${voffset 6}${color purple}Connections:
 ${voffset -1}${color purple}Inbound: ${alignr 164}${color}${tcp_portmon 1 32767 count}
 ${voffset -15}${color purple}                      Outbound: ${alignr}${color}${tcp_portmon 32768 61000 count} 
 ${voffset -2}${color purple}Ping (Google): ${alignr}${color}${texeci 10 ping -c 1 -W 1 74.125.29.105 | grep time= | awk '{print $7}' | cut -c 6-100} ms 
 ${voffset -2}${color purple}Ping (Bing): ${alignr}${color}${texeci 10 ping -c 1 -W 1 204.79.197.200 | grep time= | awk '{print $7}' | cut -c 6-100} ms 
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
#
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈ Weather monitoring
${voffset 6}${color purple}Weather (KTTN):${alignr}${color}${execi 3600 curl -s http://weather.noaa.gov/pub/data/observations/metar/decoded/KTTN.TXT | grep "Sky conditions" | awk '{print $3}'} 
 ${voffset -1}${color purple}Temp C: ${alignr 157}${color}${execi 3600 curl -s http://weather.noaa.gov/pub/data/observations/metar/decoded/KTTN.TXT | grep "Temperature" | awk '{print $4}' | cut -c2-100}°C
 ${voffset -15}${color purple}                      Temp F: ${alignr}${color}${execi 3600 curl -s http://weather.noaa.gov/pub/data/observations/metar/decoded/KTTN.TXT | grep "Temperature" | awk '{print $2}'}°F 
 ${voffset -2}${color purple}Dew Point C: ${alignr 157}${color}${execi 3600 curl -s http://weather.noaa.gov/pub/data/observations/metar/decoded/KTTN.TXT | grep "Dew Point" | awk '{print $5}' | cut -c2-100}°C
 ${voffset -15}${color purple}                      Dew Point F: ${alignr 7}${color}${execi 3600 curl -s http://weather.noaa.gov/pub/data/observations/metar/decoded/KTTN.TXT | grep "Dew Point" | awk '{print $3}'}°F${endif}
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
#
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈ Environment monitoring
${voffset -10}${color cyan}${stippled_hr}
${voffset -5}${color purple}Processes${alignr 3}PID   CPU%   MEM%
${voffset -1}${color lightblue} ${top name 1} ${color}${top pid 1} ${top cpu 1} ${top mem 1}
${voffset -2}${color lightblue} ${top name 2} ${color}${top pid 2} ${top cpu 2} ${top mem 2}
${voffset -2}${color lightblue} ${top name 3} ${color}${top pid 3} ${top cpu 3} ${top mem 3}
${voffset -2}${color lightblue} ${top name 4} ${color}${top pid 4} ${top cpu 4} ${top mem 4}
${voffset -2}${color lightblue} ${top name 5} ${color}${top pid 5} ${top cpu 5} ${top mem 5}
# ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈

答案1

我找到了解决上述问题的方法。我一直在尝试使用 voffset,最后想出了这个方法来结束 conky 配置。

${voffset -42}

这巧妙地删除了错误的空格。感谢您在我提出这个问题时给予我意见。我希望这个修复能帮助其他遇到这个问题的人。

相关内容