Day of Conky

The Day of Ubuntu wallpaper is a beautiful and subtle transitioning wallpaper that makes your desktop scene of a tree in a field change with the passing of time. To complement this effect I've written a conky configuration that changes colour along with it.



Day of Conky DuskDay of Conky DawnDay of Conky MidnightDay of Conky Noon

Feel free to make use of the script if you like it, although you'll probably have to modify it to suit your computer. Currently it's set up for a dual core computer with an nvidia graphics card and a screen resolution of 1366 x 768. The script I use to display available updates is based on one by plb (if you make use of it remember to check that the file path in the conky script matches the location of the script).


Here's the conky code, enjoy!

# DAY OF CONKY
# version 1.4
# by Oliver Schmid

# Behaviour
double_buffer yes
update_interval 1

# Window
own_window no
own_window_transparent yes
draw_borders no
draw_shades no

# Position
gap_x 10
gap_y -85
alignment bottom_left

# Font
use_xft yes
xftfont bauhaus:pixelsize=10

# Colour Start time Colour
default_color 5E6A73 # 0:00 midnight
color1 5E6941 # 2:20 50% midnight / dawn
color2 5E680E # 5:00 dawn
color3 5A6D0F # 7:54 33% dawn / noon
color4 567211 # 10:00 69% dawn / noon
color5 527612 # 12:17 noon
color6 406A2F # 14:54 33% noon / dusk
color7 2F5F48 # 17:00 69% noon / dusk
color8 1B5267 # 18:40 dusk
color9 3D5E6D # 23:00 50% dusk / midnight

#### Day of Ubuntu Transitions ####
# 1:00 - 2:00 midnight #
# 2:00 - 6:00 midnight -> dawn #
# 6:00 - 7:00 dawn #
# 7:00 - 13:00 dawn -> noon #
# 13:00 - 14:00 noon #
# 14:00 - 20:00 noon -> dusk #
# 20:00 - 21:00 dusk #
# 21:00 - 1:00 dusk -> midnight #
###################################


TEXT
${if_match ${time %k%M}>=220}${color1}${endif}
${if_match ${time %k%M}>=500}${color2}${endif}
${if_match ${time %k%M}>=754}${color3}${endif}
${if_match ${time %k%M}>=1000}${color4}${endif}
${if_match ${time %k%M}>=1217}${color5}${endif}
${if_match ${time %k%M}>=1454}${color6}${endif}
${if_match ${time %k%M}>=1700}${color7}${endif}
${if_match ${time %k%M}>=1840}${color8}${endif}
${if_match ${time %k%M}>=2300}${color9}${endif}
${if_match ${time %k%M}>=2345}${color}${endif}
CPU0: ${freq_g 0} GHz ${cpugraph 0 7,45 888888 888888}
CPU1: ${freq_g 1} GHz ${cpugraph 1 7,45 888888 888888}

${voffset -39}${offset 135}[ ${loadavg 1} : ${loadavg 2} : ${loadavg 3} ]
${offset 165}${running_processes} / ${processes}

${voffset -39}${offset 240}MEM: ${offset 5}${membar 7,45}
${offset 240}SWAP: ${swapbar 7,45}

${voffset -39}${offset 333}HDD: ${fs_bar 7,45 /}
${offset 333}IO: ${offset 13}${diskiograph /dev/sda1 7,45 888888 888888}

${voffset -39}${offset 423}CPU: ${acpitemp}°C
${offset 423}GPU: ${execi 60 nvidia-settings -t -q GPUCoreTemp}°C

${voffset -27}${offset 630}Uptime: ${uptime_short}

${voffset -27}${offset 1230}${texeci 600 /home/oliver/Programs/availableUpdates.sh}


And the available updates script:

#!/bin/sh
# Conky script to display available updates
# by Oliver Schmid

NUMUPDATES=$(aptitude search "~U" | wc -l)
if [ $NUMUPDATES -eq 1 ]; then
echo $NUMUPDATES Update Available
elif [ $NUMUPDATES -gt 0 ]; then
echo $NUMUPDATES Updates Available
fi


Update Dec 18, 2009: There may be a better way to do this by modifying this lua script.


Update Dec 24, 2009: A few minor changes in the timing and colours, compare version numbers for latest source.

1 comments:

Johannes said...

Just beautiful, thank you!
Wish these kind of things would be included by default...

Post a Comment