SEARCH

Enter your search query in the box above ^, or use the forum search tool.

You are not logged in.

#2551 2011-08-07 21:56:05

xeNULL
#! Pirate
From: The Internet
Registered: 2011-01-23
Posts: 811

Re: My Conky Config

It is done...for now

conky2.png

conkyrc:

#==============================================================================
#  ConkyHXR
#
#  Date    : 03/08/2011
#  author  : xeNULL
#  version : v0.1
#  license : Distributed under the terms of GNU GPL version 2 or later
#
#==============================================================================

background yes
update_interval 1

cpu_avg_samples 2
net_avg_samples 2
temperature_unit celsius
short_units yes

double_buffer yes
no_buffers yes
text_buffer_size 2048

gap_x 25
gap_y 40

minimum_size 180 750
maximum_width 180
own_window yes
own_window_type desktop
own_window_transparent yes
own_window_hints undecorate,sticky,skip_taskbar,skip_pager,below
border_inner_margin 0
border_outer_margin 0
alignment tr

draw_shades no
draw_outline no
draw_borders no
draw_graph_borders no

default_bar_size 150 20

override_utf8_locale yes
use_xft yes
xftfont Pragmata:9
xftalpha 0.5
uppercase no

default_color FFFFFF
color1 DDDDDD
color2 AAAAAA
color3 888888
color4 FFFFFF

lua_load ~/.scripts/conkyHXR.lua
lua_draw_hook_post main

TEXT
${voffset 25}${font Pragmata:size=9} /// S Y S T E M ///

${voffset 25}${color4}${offset 55}${cpugraph 20,115 999999 ffffff}${color}
${voffset -20}${offset 45}${font Pragmata:size=9}${color}CPU${offset 65}
${offset 55}${font Pragmata:size=8,weight:normal}${color4}${top name 1}${alignr}${top cpu 1}%
${offset 55}${font Pragmata:size=8,weight:normal}${color1}${top name 2}${alignr}${top cpu 2}%
${offset 55}${font Pragmata:size=8,weight:normal}${color2}${top name 3}${alignr}${top cpu 3}%
${offset 55}${font Pragmata:size=8,weight:normal}${color3}${top name 4}${alignr}${top cpu 4}%
${offset 55}${font Pragmata:size=8,weight:normal}${color3}${top name 5}${alignr}${top cpu 5}%

${voffset 30}${color4}${offset 55}${memgraph 5,115  999999 ffffff -l}${color}
${voffset -15}${offset 45}${font Pragmata:size=9}${color}MEM
${offset 55}${font Pragmata:size=8,weight:normal}${color4}${top_mem name 1}${alignr}${top_mem mem 1}%
${offset 55}${font Pragmata:size=8,weight:normal}${color1}${top_mem name 2}${alignr}${top_mem mem 2}%
${offset 55}${font Pragmata:size=8,weight:normal}${color2}${top_mem name 3}${alignr}${top_mem mem 3}%
${offset 55}${font Pragmata:size=8,weight:normal}${color3}${top_mem name 4}${alignr}${top_mem mem 4}%
${offset 55}${font Pragmata:size=8,weight:normal}${color3}${top_mem name 4}${alignr}${top_mem mem 5}%

${voffset 25}${offset 55}${diskiograph 20,115 999999 ffffff}
${voffset -20}${offset 45}${font Pragmata:size=9}${color}DISK
${offset 55}${font Pragmata:size=8,weight:normal${alignr}}${color}/ ${fs_used /} -  ${fs_size /}

${voffset 5}${color4}${offset 10}${upspeedgraph eth0 20,70 999999 ffffff}${alignr}${offset 0}${upspeedgraph wlan0 20,70 999999 ffffff}${color}
${color4}${offset 10}${downspeedgraph eth0 20,70 999999 ffffff}${alignr}${offset 0}${downspeedgraph wlan0 20,70 999999 ffffff}${color}
  ${voffset 8}${offset 10}${font Pragmata:size=9}${color}ETHERNET       WIRELESS
  ${offset 10}${color2}${font Pragmata:size=8,weight:normal}${addr eth0}${alignr}${offset -10}${addr wlan0}

${voffset 42}${offset 45}${font Pragmata:size=9}${color4}MUSIC${color}
${offset 55}${hr}
${font Pragmata:size=8}${offset 55}${color4}Song${color} 
${offset 55}${color3}${exec mocp -Q %song}${color}
${offset 55}${color4}Artist${color} 
${offset 55}${color3}${exec mocp -Q %artist}${color}
${offset 55}${color4}Album${color} 
${offset 55}${color3}${exec mocp -Q %album}${color}
${offset 55}${hr}
${offset 55}${alignr}${color3}${exec mocp -Q %ct} - ${exec mocp -Q %tt}${color}
${voffset -12}${offset 55}${blink ${color4}${exec mocp -Q %state}${color}

${image ~/.scripts/usdesk.png -p 3,0 -s 30x10}${image ~/.scripts/usdesk.png -p 47,0 -s 30x10}${image ~/.scripts/usdesk.png -p 91,0 -s 30x10}${image ~/.scripts/usdesk.png -p 135,0 -s 30x10}${if_match ${desktop}==1}${image ~/.scripts/sdesk.png -p 3,0 -s 30x10}${endif}${if_match ${desktop}==2}${image ~/.scripts/sdesk.png -p 47,0 -s 30x10}${endif}${if_match ${desktop}==3}${image ~/.scripts/sdesk.png -p 91,0 -s 30x10}${endif}${if_match ${desktop}==4}${image ~/.scripts/sdesk.png -p 135,0 -s 30x10}${endif}
${image ~/images/wallpapers/avatar.png -p 3,640 -s 100x100}

lua script [needs mixer variable editing if you use 'Master']:

--==============================================================================
--  ConkyHXR.lua
--
--  Date    : 03/08/2011
--  Author  : xeNULL
--  Version : v0.1
--  License : Distributed under the terms of GNU GPL version 2 or later
--
--==============================================================================

require 'cairo'


--------------------------------------------------------------------------------
--                                                                    gauge DATA
gauge = {
{
    name='cpu',                    arg='cpu0',                  max_value=100,
    x=40,                          y=90,
    graph_radius=24,
    graph_thickness=5,
    graph_start_angle=180,
    graph_unit_angle=2.7,          graph_unit_thickness=2.7,
    graph_bg_colour=0xffffff,      graph_bg_alpha=0.3,
    graph_fg_colour=0x111111,      graph_fg_alpha=0.5,
    hand_fg_colour=0xFFFFFF,       hand_fg_alpha=1.0,
    txt_radius=34,
    txt_weight=0,                  txt_size=8.0,
    txt_fg_colour=0xFFFFFF,        txt_fg_alpha=1.0,
    graduation_radius=28,
    graduation_thickness=0,        graduation_mark_thickness=1,
    graduation_unit_angle=27,
    graduation_fg_colour=0xFFFFFF, graduation_fg_alpha=0.3,
    caption='',
    caption_weight=1,              caption_size=8.0,
    caption_fg_colour=0xFFFFFF,    caption_fg_alpha=0.3,
},
{
    name='cpu',                    arg='cpu1',                  max_value=100,
    x=40,                          y=90,
    graph_radius=18,
    graph_thickness=5,
    graph_start_angle=180,
    graph_unit_angle=2.7,          graph_unit_thickness=2.7,
    graph_bg_colour=0xffffff,      graph_bg_alpha=0.3,
    graph_fg_colour=0x111111,      graph_fg_alpha=0.5,
    hand_fg_colour=0xFFFFFF,       hand_fg_alpha=1.0,
    txt_radius=10,
    txt_weight=0,                  txt_size=8.0,
    txt_fg_colour=0xFFFFFF,        txt_fg_alpha=1.0,
    graduation_radius=28,
    graduation_thickness=0,        graduation_mark_thickness=1,
    graduation_unit_angle=27,
    graduation_fg_colour=0xFFFFFF, graduation_fg_alpha=0.3,
    caption='',
    caption_weight=1,              caption_size=8.0,
    caption_fg_colour=0xFFFFFF,    caption_fg_alpha=0.3,
},
{
    name='memperc',                arg='',                      max_value=100,
    x=40,                          y=210,
    graph_radius=24,
    graph_thickness=5,
    graph_start_angle=180,
    graph_unit_angle=2.7,          graph_unit_thickness=2.7,
    graph_bg_colour=0xffffff,      graph_bg_alpha=0.3,
    graph_fg_colour=0x111111,      graph_fg_alpha=0.5,
    hand_fg_colour=0xFFFFFF,       hand_fg_alpha=1.0,
    txt_radius=34,
    txt_weight=0,                  txt_size=8.0,
    txt_fg_colour=0xFFFFFF,        txt_fg_alpha=1.0,
    graduation_radius=23,
    graduation_thickness=0,        graduation_mark_thickness=2,
    graduation_unit_angle=27,
    graduation_fg_colour=0xFFFFFF, graduation_fg_alpha=0.5,
    caption='',
    caption_weight=1,              caption_size=8.0,
    caption_fg_colour=0xFFFFFF,    caption_fg_alpha=0.3,
},
{
    name='fs_used_perc',           arg='/',                     max_value=100,
    x=40,                          y=340,
    graph_radius=24,
    graph_thickness=5,
    graph_start_angle=180,
    graph_unit_angle=2.7,          graph_unit_thickness=2.7,
    graph_bg_colour=0xffffff,      graph_bg_alpha=0.3,
    graph_fg_colour=0x111111,      graph_fg_alpha=0.5,
    hand_fg_colour=0xFFFFFF,       hand_fg_alpha=1.0,
    txt_radius=34,
    txt_weight=0,                  txt_size=8.0,
    txt_fg_colour=0xFFFFFF,        txt_fg_alpha=1.0,
    graduation_radius=23,
    graduation_thickness=0,        graduation_mark_thickness=2,
    graduation_unit_angle=27,
    graduation_fg_colour=0xFFFFFF, graduation_fg_alpha=0.3,
    caption='',
    caption_weight=1,              caption_size=8.0,
    caption_fg_colour=0xFFFFFF,    caption_fg_alpha=0.5,
},
{
    name='downspeedf',           arg='eth0',                     max_value=100,
    x=40,                          y=425,
    graph_radius=24,
    graph_thickness=5,
    graph_start_angle=180,
    graph_unit_angle=2.7,          graph_unit_thickness=2.7,
    graph_bg_colour=0xffffff,      graph_bg_alpha=0.3,
    graph_fg_colour=0x111111,      graph_fg_alpha=0.5,
    hand_fg_colour=0xFFFFFF,       hand_fg_alpha=1.0,
    txt_radius=34,
    txt_weight=0,                  txt_size=8.0,
    txt_fg_colour=0xFFFFFF,        txt_fg_alpha=1.0,
    graduation_radius=28,
    graduation_thickness=0,        graduation_mark_thickness=1,
    graduation_unit_angle=27,
    graduation_fg_colour=0xFFFFFF, graduation_fg_alpha=0.3,
    caption='Down',
    caption_weight=1,              caption_size=6.0,
    caption_fg_colour=0xFFFFFF,    caption_fg_alpha=0.5,
},
{
    name='upspeedf',           arg='eth0',                     max_value=100,
    x=40,                          y=425,
    graph_radius=18,
    graph_thickness=5,
    graph_start_angle=180,
    graph_unit_angle=2.7,          graph_unit_thickness=2.7,
    graph_bg_colour=0xffffff,      graph_bg_alpha=0.3,
    graph_fg_colour=0x111111,      graph_fg_alpha=0.5,
    hand_fg_colour=0xFFFFFF,       hand_fg_alpha=1.0,
    txt_radius=10,
    txt_weight=0,                  txt_size=8.0,
    txt_fg_colour=0xFFFFFF,        txt_fg_alpha=1.0,
    graduation_radius=28,
    graduation_thickness=0,        graduation_mark_thickness=1,
    graduation_unit_angle=27,
    graduation_fg_colour=0xFFFFFF, graduation_fg_alpha=0.3,
    caption='Up',
    caption_weight=1,              caption_size=6.0,
    caption_fg_colour=0xFFFFFF,    caption_fg_alpha=0.5,
},
{
    name='downspeedf',           arg='wlan0',                     max_value=100,
    x=135,                          y=425,
    graph_radius=24,
    graph_thickness=5,
    graph_start_angle=180,
    graph_unit_angle=2.7,          graph_unit_thickness=2.7,
    graph_bg_colour=0xffffff,      graph_bg_alpha=0.3,
    graph_fg_colour=0x111111,      graph_fg_alpha=0.5,
    hand_fg_colour=0xFFFFFF,       hand_fg_alpha=1.0,
    txt_radius=34,
    txt_weight=0,                  txt_size=8.0,
    txt_fg_colour=0xFFFFFF,        txt_fg_alpha=1.0,
    graduation_radius=28,
    graduation_thickness=0,        graduation_mark_thickness=1,
    graduation_unit_angle=27,
    graduation_fg_colour=0xFFFFFF, graduation_fg_alpha=0.3,
    caption='Down',
    caption_weight=1,              caption_size=6.0,
    caption_fg_colour=0xFFFFFF,    caption_fg_alpha=0.5,
},
{
    name='upspeedf',           arg='wlan0',                     max_value=100,
    x=135,                          y=425,
    graph_radius=18,
    graph_thickness=5,
    graph_start_angle=180,
    graph_unit_angle=2.7,          graph_unit_thickness=2.7,
    graph_bg_colour=0xffffff,      graph_bg_alpha=0.3,
    graph_fg_colour=0x111111,      graph_fg_alpha=0.5,
    hand_fg_colour=0xFFFFFF,       hand_fg_alpha=1.0,
    txt_radius=10,
    txt_weight=0,                  txt_size=8.0,
    txt_fg_colour=0xFFFFFF,        txt_fg_alpha=1.0,
    graduation_radius=28,
    graduation_thickness=0,        graduation_mark_thickness=1,
    graduation_unit_angle=27,
    graduation_fg_colour=0xFFFFFF, graduation_fg_alpha=0.3,
    caption='Up',
    caption_weight=1,              caption_size=6.0,
    caption_fg_colour=0xFFFFFF,    caption_fg_alpha=0.5,
},
{
    name='mixer',                arg='PCM',                      max_value=100,
    x=40,                          y=542,
    graph_radius=24,
    graph_thickness=5,
    graph_start_angle=180,
    graph_unit_angle=2.7,          graph_unit_thickness=2.7,
    graph_bg_colour=0xffffff,      graph_bg_alpha=0.3,
    graph_fg_colour=0x111111,      graph_fg_alpha=0.5,
    hand_fg_colour=0xFFFFFF,       hand_fg_alpha=1.0,
    txt_radius=34,
    txt_weight=0,                  txt_size=8.0,
    txt_fg_colour=0xFFFFFF,        txt_fg_alpha=1.0,
    graduation_radius=23,
    graduation_thickness=0,        graduation_mark_thickness=2,
    graduation_unit_angle=27,
    graduation_fg_colour=0xFFFFFF, graduation_fg_alpha=0.5,
    caption='',
    caption_weight=1,              caption_size=8.0,
    caption_fg_colour=0xFFFFFF,    caption_fg_alpha=0.3,
},
}

-------------------------------------------------------------------------------
--                                                                 rgb_to_r_g_b
-- converts color in hexa to decimal
--
function rgb_to_r_g_b(colour, alpha)
    return ((colour / 0x10000) % 0x100) / 255., ((colour / 0x100) % 0x100) / 255., (colour % 0x100) / 255., alpha
end

-------------------------------------------------------------------------------
--                                                            angle_to_position
-- convert degree to rad and rotate (0 degree is top/north)
--
function angle_to_position(start_angle, current_angle)
    local pos = current_angle + start_angle
    return ( ( pos * (2 * math.pi / 360) ) - (math.pi / 2) )
end


-------------------------------------------------------------------------------
--                                                              draw_gauge_ring
-- displays gauges
--
function draw_gauge_ring(display, data, value)
    local max_value = data['max_value']
    local x, y = data['x'], data['y']
    local graph_radius = data['graph_radius']
    local graph_thickness, graph_unit_thickness = data['graph_thickness'], data['graph_unit_thickness']
    local graph_start_angle = data['graph_start_angle']
    local graph_unit_angle = data['graph_unit_angle']
    local graph_bg_colour, graph_bg_alpha = data['graph_bg_colour'], data['graph_bg_alpha']
    local graph_fg_colour, graph_fg_alpha = data['graph_fg_colour'], data['graph_fg_alpha']
    local hand_fg_colour, hand_fg_alpha = data['hand_fg_colour'], data['hand_fg_alpha']
    local graph_end_angle = (max_value * graph_unit_angle) % 360

    -- background ring
    cairo_arc(display, x, y, graph_radius, angle_to_position(graph_start_angle, 0), angle_to_position(graph_start_angle, graph_end_angle))
    cairo_set_source_rgba(display, rgb_to_r_g_b(graph_bg_colour, graph_bg_alpha))
    cairo_set_line_width(display, graph_thickness)
    cairo_stroke(display)

    -- arc of value
    local val = value % (max_value + 1)
    local start_arc = 0
    local stop_arc = 0
    local i = 1
    while i <= val do
        start_arc = (graph_unit_angle * i) - graph_unit_thickness
        stop_arc = (graph_unit_angle * i)
        cairo_arc(display, x, y, graph_radius, angle_to_position(graph_start_angle, start_arc), angle_to_position(graph_start_angle, stop_arc))
        cairo_set_source_rgba(display, rgb_to_r_g_b(graph_fg_colour, graph_fg_alpha))
        cairo_stroke(display)
        i = i + 1
    end
    local angle = start_arc

    -- hand
    start_arc = (graph_unit_angle * val) - (graph_unit_thickness * 2)
    stop_arc = (graph_unit_angle * val)
    cairo_arc(display, x, y, graph_radius, angle_to_position(graph_start_angle, start_arc), angle_to_position(graph_start_angle, stop_arc))
    cairo_set_source_rgba(display, rgb_to_r_g_b(hand_fg_colour, hand_fg_alpha))
    cairo_stroke(display)

    -- graduations marks
    local graduation_radius = data['graduation_radius']
    local graduation_thickness, graduation_mark_thickness = data['graduation_thickness'], data['graduation_mark_thickness']
    local graduation_unit_angle = data['graduation_unit_angle']
    local graduation_fg_colour, graduation_fg_alpha = data['graduation_fg_colour'], data['graduation_fg_alpha']
    if graduation_radius > 0 and graduation_thickness > 0 and graduation_unit_angle > 0 then
        local nb_graduation = graph_end_angle / graduation_unit_angle
        local i = 0
        while i < nb_graduation do
            cairo_set_line_width(display, graduation_thickness)
            start_arc = (graduation_unit_angle * i) - (graduation_mark_thickness / 2)
            stop_arc = (graduation_unit_angle * i) + (graduation_mark_thickness / 2)
            cairo_arc(display, x, y, graduation_radius, angle_to_position(graph_start_angle, start_arc), angle_to_position(graph_start_angle, stop_arc))
            cairo_set_source_rgba(display,rgb_to_r_g_b(graduation_fg_colour,graduation_fg_alpha))
            cairo_stroke(display)
            cairo_set_line_width(display, graph_thickness)
            i = i + 1
        end
    end

    -- text
    local txt_radius = data['txt_radius']
    local txt_weight, txt_size = data['txt_weight'], data['txt_size']
    local txt_fg_colour, txt_fg_alpha = data['txt_fg_colour'], data['txt_fg_alpha']
    local movex = txt_radius * math.cos(angle_to_position(graph_start_angle, angle))
    local movey = txt_radius * math.sin(angle_to_position(graph_start_angle, angle))
    cairo_select_font_face (display, "ubuntu", CAIRO_FONT_SLANT_NORMAL, txt_weight)
    cairo_set_font_size (display, txt_size)
    cairo_set_source_rgba (display, rgb_to_r_g_b(txt_fg_colour, txt_fg_alpha))
    cairo_move_to (display, x + movex - (txt_size / 2), y + movey + 3)
    cairo_show_text (display, value)
    cairo_stroke (display)

    -- caption
    local caption = data['caption']
    local caption_weight, caption_size = data['caption_weight'], data['caption_size']
    local caption_fg_colour, caption_fg_alpha = data['caption_fg_colour'], data['caption_fg_alpha']
    local tox = graph_radius * (math.cos((graph_start_angle * 2 * math.pi / 360)-(math.pi/2)))
    local toy = graph_radius * (math.sin((graph_start_angle * 2 * math.pi / 360)-(math.pi/2)))
    cairo_select_font_face (display, "ubuntu", CAIRO_FONT_SLANT_NORMAL, caption_weight);
    cairo_set_font_size (display, caption_size)
    cairo_set_source_rgba (display, rgb_to_r_g_b(caption_fg_colour, caption_fg_alpha))
    cairo_move_to (display, x + tox + 5, y + toy + 1)
    -- bad hack but not enough time !
    if graph_start_angle < 105 then
        cairo_move_to (display, x + tox - 30, y + toy + 1)
    end
    cairo_show_text (display, caption)
    cairo_stroke (display)
end


-------------------------------------------------------------------------------
--                                                               go_gauge_rings
-- loads data and displays gauges
--
function go_gauge_rings(display)
    local function load_gauge_rings(display, data)
        local str, value = '', 0
        str = string.format('${%s %s}',data['name'], data['arg'])
        str = conky_parse(str)
        value = tonumber(str)
        draw_gauge_ring(display, data, value)
    end
    
    for i in pairs(gauge) do
        load_gauge_rings(display, gauge[i])
    end
end

-------------------------------------------------------------------------------
--                                                                         MAIN
function conky_main()
    if conky_window == nil then 
        return
    end

    local cs = cairo_xlib_surface_create(conky_window.display, conky_window.drawable, conky_window.visual, conky_window.width, conky_window.height)
    local display = cairo_create(cs)
    
    local updates = conky_parse('${updates}')
    update_num = tonumber(updates)
    
    if update_num > 5 then
        go_gauge_rings(display)
    end

    cairo_surface_destroy(cs)
    cairo_destroy(display)

end

The images used in the conky can be made by you but if you want the ones in the conky ask me =]

Last edited by xeNULL (2011-08-07 22:01:25)


AKA xii on #crunchbang #!WMFS2
dotshare | dA | 1 1 0 1 0 1 0 0 0

Offline

Help fund CrunchBang, donate to the project!

#2552 2011-08-08 18:15:16

ackernan
#! Junkie
Registered: 2011-01-10
Posts: 403

Re: My Conky Config

xeNULL wrote:

It is done...for now

conky2.png

Looks good. :-)

Offline

#2553 2011-08-08 23:51:27

xeNULL
#! Pirate
From: The Internet
Registered: 2011-01-23
Posts: 811

Re: My Conky Config

ackernan wrote:

Looks good. :-)

Thanks man =]


AKA xii on #crunchbang #!WMFS2
dotshare | dA | 1 1 0 1 0 1 0 0 0

Offline

#2554 2011-08-09 10:21:20

kbmonkey
#! Die Hard
From: South Africa
Registered: 2011-01-14
Posts: 879
Website

Re: My Conky Config

@dlm955 that bargraph is uber! I love that look, so LED. Might check out that lua script for it.

@Sector11, wow some rant! He he. What if Google wanted to rush out the OS so they improvised on the hardware for the meanwhile, hence the Caps keys. That aside, I'm anti Caps lock, it's just a glorified cruise control for 'cool' cool xmodmap it to something useful, perhaps xbill is a suitable replacement lol

@xeNULL you have made it so nice!

Offline

#2555 2011-08-09 10:59:28

kbmonkey
#! Die Hard
From: South Africa
Registered: 2011-01-14
Posts: 879
Website

Re: My Conky Config

Sector11 wrote:

Yea, pure genius that was... Are you going to show us the conky?

Sure smile

http://ompldr.org/vOXRrdA

(the ompload bash script doesn't make thumbs)

# minfo conky -- for the minimalist!
# 
# minimalist conky is a horizontal style config.
# configure your desktop margins so conky is always visible.
# 
# made from scratch using the conky wiki as reference.
# 
# features:
#  * the usual system infos, includes top 2 procs cpu%
#  * now playing, todo items and weather
# 
# notes:
#  * includes examples for now playing via deadbeef, mpd and moc
#  * todo item from plain text file ~/todo, first two lines sed'd into one
#  * see bottom for examples and notes
# 
# feel free to tweak :)
# 
# ~ kbmonkey
# 
# # # # # # # # # # # # # #

alignment                   top_left
use_xft                     yes
xftfont                     Monospace:size=9
xftalpha                    1
out_to_console              no
update_interval             3
draw_shades                 no
own_window                  yes
own_window_type             override
own_window_transparent      no
double_buffer               yes
#own_window_type             normal
stippled_borders            1
border_width                1
draw_borders                no
gap_x                       6
gap_y                       0
use_spacer                  yes

# colors
# # # # # # # # # # # # # #
default_color               ffff00  # the border and pipes between outputs
own_window_colour           000000  # background
color1                      7e9ee0  # processing
color2                      88cc88  # networking
color3                      9999cc  # disks
color4                      d3c76e  # top
color5                      dddd00  # irc
color6                      b09ce8  # weather
color7                      e0af7e  # todo
color8                      88aaff  # now playing
color9                      d3c76e  # infos
 
# [first line] # # # # # # # # # # # # #

TEXT
${color9}$nodename resurrected ${uptime_short} ago ${color}☼${color6} ${execi 300 ~/.conky/configs/weather.sh "AFR|ZA|SF005|DURBAN"} ${color}≡${color1} [cpu ${cpubar 10,60} [ram ${membar 10,60} [swap ${color1}${swapbar 10,60} ${color}≡${color2} [ra0 ${downspeed ra0} ${downspeedgraph ra0 10,60 006600 00ff00 -l} ${color}≡${color3} [/ ${fs_bar 10,60 /} [/home ${fs_bar 10,60 /home} [/data ${fs_bar 10,60 /mnt/data} ${color}≡${alignr}${color4} [${top name 1} ${top cpu 1}%][${top name 2} ${top cpu 2}%]
#
# [uplink ${upspeed ra0} ${upspeedgraph ra0 10,60 006600 00ff00} ${color}≡${color3} 
# 
# [second line] # # # # # # # # # # # # #
${color7}TODO: ${exec cat todo | head -n2 | sed 'N;s/\n/ /;'}  ${alignc}${color5} ${exec cat .conky-im | tail -2 | sed 'N;s/\n/ \| /;s/\t/\ /g;'} ${alignr} ${color8} ${if_running mpd} ♫ ${exec ncmpcpp --now-playing "{{%t by %a}|{%f}}"}${endif}
#
#
#
# [notes]
# # # # # # # # # # # # # #
#
# now playing codes:
#  * moc = ${color8}${if_running mocp}${exec mocp -Q %title}${endif}
#
#  * deadbeef = ${color8}${if_running deadbeef-main}${exec deadbeef --nowplaying '%t, by %a'}${endif}
#
#  * mpd via ncmpcpp = ncmpcpp --now-playing "%t by %a"

Offline

#2556 2011-08-09 13:48:42

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: My Conky Config

dlm955 wrote:

Well SECTOR 11 here it is click on pic to get it larger

dcKqJ.png That should be a link to a pic of my desktop.

The cruncbang symbols on top by clock I made with gimp they have a black background so they only blend with one.

OK, I did it .. late but it's there:  dlm955 Featured on Conky Pitstop and in the Gallery!.

There's actually a few more more I am going to put up but life and been sidetracked with other stuff has caused a delay  big_smile.


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#2557 2011-08-09 16:00:54

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: My Conky Config

kbmonkey wrote:
Sector11 wrote:

Yea, pure genius that was... Are you going to show us the conky?

Sure smile

http://ompldr.org/vOXRrdA

(the ompload bash script doesn't make thumbs)

It does for me:
tOXRwMA

tOXRwMg

I stand corrected... I didn't see the "bash script" part:

if you could to a "rename" in the bash script:

tOXRrdA

Changing this part:

.org/v

to this:

.org/t

as seen here:

[url=http://ompldr.org/vOXRrdA][img]http://ompldr.org/tOXRrdA[/img][/url]

you'd have it.  That .org/t gives you the thumb.

Thanks for the code.  big_smile

What bash script?


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#2558 2011-08-09 16:49:07

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: My Conky Config

I gotta say ... regarding the rant  big_smile

I'm like Tom Clancy: I know I'm paranoid, but am I paranoid enough!  lol

And I use Google, they track me, I don't care, but I'd still like to keep my stuff mine as much as possible.  smile


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#2559 2011-08-11 11:01:40

ackernan
#! Junkie
Registered: 2011-01-10
Posts: 403

Re: My Conky Config

I use a lua script to create my conky background.  Occasionally for no reason the background will disappear for few seconds, nothing else does.  How can I fix this?  It's nothing major, just annoying.

http://dl.dropbox.com/u/23122621/Selection_055.png


######################
# - Conky settings - #
######################
background yes
update_interval 1
 
cpu_avg_samples 2
net_avg_samples 2
 
override_utf8_locale yes
 
double_buffer yes
no_buffers yes
 
text_buffer_size 10240
#imlib_cache_size 0
 
#############################
# - 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
 
border_inner_margin 0
border_outer_margin 0
 
minimum_size 290 730
maximum_width 300
 
alignment tr
gap_x 10
gap_y 5
 
#########################
# - Graphics settings - #
#########################
draw_shades no
draw_outline no
draw_borders no
draw_graph_borders no
 
#####################
# - Text settings - #
#####################
use_xft yes
xftfont Santana:size=9:style=bold
xftalpha 0.8
 
uppercase no
 
default_color FFFFFF

temperature_unit fahrenheit
if_up_strictness address


####
## Load Lua for bargraphs (required)
## Set the path to your script here.
#
lua_load ~/.conky/new/bg.lua

TEXT
${lua conky_draw_bg 20 0 0 290 725 0x000000 0.4}
#
# System info
#
${image ~/.conky/images/tux_graduate.png -p 5,5 -s 48x48}
${voffset -30}${goto 60} ${nodename}
${goto 60} ${sysname} ${kernel} on ${machine}
${goto 60} Uptime:  ${uptime}
${goto 60} ${execpi 300 lsb_release -d | cut -c 14-50}
#
# Time
#
${voffset -15}${goto 60}${font FFF Tusj:size=60}${time %H:}${font}
${voffset -65}${goto 200}${font FFF Tusj:size=25}${color DFEC88}${time %S}${font}${color}
${voffset -10}${goto 140}${font FFF Tusj:size=60}${time %M}${font}
#
# Processor info
#
${image ~/.conky/images/processor.png -p 5,200 -s 48x48}
${goto 60}${freq}MHz   Load: ${color 88ECE0}${loadavg}${color}
${goto 60}Core 1 Usage: ${color DFEC88}${cpu cpu1}% ${color} ${alignr 5}${cpubar cpu1 6,115}
${goto 60}Core 2 Usage: ${color DFEC88}${cpu cpu2}% ${color} ${alignr 5}${cpubar cpu2 6,115}
${goto 60}Core 3 Usage: ${color DFEC88}${cpu cpu3}% ${color} ${alignr 5}${cpubar cpu3 6,115}
${goto 60}Core 4 Usage: ${color DFEC88}${cpu cpu4}% ${color} ${alignr 5}${cpubar cpu4 6,115}
${goto 60}CPU Temp: ${color 88ECE0}${acpitemp}° F${color}
#
# Memory info
#
${image ~/.conky/images/memory.png -p 5,262 -s 48x48}
${voffset -10}${goto 60}RAM:   ${memperc}% ${alignr 5}${membar 6,155} 
${goto 60}Swap:  ${swapperc}%   ${alignr 5}${swapbar 6,155} 
#
# Disk info
#
${image ~/.conky/images/hdd.png -p 5,320 -s 48x48}
${voffset -10}${goto 60}Root:   ${fs_size /} ${alignr 5}${fs_free /} free
${goto 60}Home:  ${fs_size /home} ${alignr 5}${fs_free /home} free
${goto 60}${if_existing /media/Linux}Linux:  ${fs_size /media/Linux} ${alignr 5}${fs_free /media/Linux} free${else}Linux:  Not Mounted${endif}
${goto 60}${if_existing /media/Stuff}Stuff:  ${fs_size /media/Stuff} ${alignr 5}${fs_free /media/Stuff} free${else}Stuff:   Not mounted${endif}
${goto 60}Disk temp: ${color 88ECE0}${execpi 300 hddtemp -u f /dev/sda | cut -c 35-40}${color}
#
# Network info
#
${if_up eth1}${image ~/.conky/images/wireless.png -p 5,405 -s 48x48}
${voffset -10}${goto 60}${font size=12}Wireless${font}
${goto 60}Internal IP: ${addr eth1}
${goto 60}External IP: ${exec wget -q -O - checkip.dyndns.org | sed -e 's/.*Current IP Address: //' -e 's/<.*$//'}
${goto 60}${downspeedgraph eth1 25,112 110000 520000 -t} ${upspeedgraph eth1 25,112 001100 005200 -t}
${voffset -40}${font size=12}${goto 85}${downspeed eth1}${goto 200}${upspeed eth1}${font}
${goto 60}Down${goto 125}${totaldown eth1}${goto 178}UP ${alignr 5}${totalup eth1}
#
# Weather info
#
${execpi 1800 conkyForecast -i --template=~/.conky/new/conkyForecast.template}
#
# If you're on ethernet
#
${else}${if_up eth0}${image ~/.conky/images/network-ethernet-connected.png -p 5,405 -s 48x48}
${voffset -10}${goto 60}${font size=12}Ethernet${font}
${goto 60}Internal IP: ${addr eth0}
${goto 60}External IP: ${exec wget -q -O - checkip.dyndns.org | sed -e 's/.*Current IP Address: //' -e 's/<.*$//'}
${goto 60}${downspeedgraph eth0 25,112 110000 520000 -t} ${upspeedgraph eth0 25,112 001100 005200 -t}
${voffset -40}${font size=12}${goto 85}${downspeed eth0}${goto 200}${upspeed eth0}${font}
${goto 60}Down${goto 125}${totaldown eth0}${goto 180}UP ${alignr 5}${totalup eth0}
#
# Weather info
#
${execpi 1800 conkyForecast -i --template=~/.conky/new/conkyForecast.template}
# This is if you have no network interace up
${else}${voffset 35}${image ~/.conky/images/network-error-2.png -p 5,405 -s 48x48}
${goto 60}${font size=12}No Network Connection${font}${endif}${endif}
--[[Background originally by londonali1010 (2009)
    ability to set any size for background mrpeachy 2011
    ability to set variables for bg in conkyrc dk75

the conky bits that matter (sample):
_ _ _ _ _ _ _ _ _ _
lua_load ~/lua/background.lua

TEXT
${lua conky_draw_bg 10 100 100 100 100 0x000000 0.2}
${lua conky_draw_bg 10 200 200 100 100 0x000000 0.2}
${lua conky_draw_bg 10 100 300 100 100 0x000000 0.2}

#${lua conky_draw_bg corner_radius x_position y_position width height color alpha}

${execpi 1800 conkyForecast --template=~/lua/test.template}
_ _ _ _ _ _ _ _ _ _
test template:
_ _ _ _ _ _ _ _ _ _
${image [--datatype=WI --startday=1]  -p 100,100 -s 90x90}
${image [--datatype=WI --startday=2]  -p 200,200 -s 90x90}
${image [--datatype=WI --startday=3]  -p 100,300 -s 90x90}
${image [--datatype=WI --startday=4]  -p 200,400 -s 90x90}
_ _ _ _ _ _ _ _ _ _

or you can have one background over the whole window
and others to highlight parts of the conky
_ _ _ _ _ _ _ _ _ _
TEXT
${lua conky_draw_bg 50 0 0 400 800 0x000000 0.2} # whole background
${lua conky_draw_bg 20 100 100 100 100 0x000000 0.2} # dark shade
${lua conky_draw_bg 0 200 200 100 100 0xffffff 0.2} # light square
${lua conky_draw_bg 50 100 300 100 100 0xff0000 0.2} # red circle
_ _ _ _ _ _ _ _ _ _

]]

require 'cairo'
local    cs, cr = nil
function rgb_to_r_g_b(colour,alpha)
return ((colour / 0x10000) % 0x100) / 255., ((colour / 0x100) % 0x100) / 255., (colour % 0x100) / 255., alpha
end
function conky_draw_bg(r,x,y,w,h,color,alpha)
if conky_window == nil then return end
if cs == nil then cairo_surface_destroy(cs) end
if cr == nil then cairo_destroy(cr) end
local cs = cairo_xlib_surface_create(conky_window.display, conky_window.drawable, conky_window.visual, conky_window.width, conky_window.height)
local cr = cairo_create(cs)
cairo_set_source_rgba (cr,rgb_to_r_g_b(color,alpha))
--top left mid circle
local xtl=x+r
local ytl=y+r
--top right mid circle
local xtr=(x+r)+((w)-(2*r))
local ytr=y+r
--bottom right mid circle
local xbr=(x+r)+((w)-(2*r))
local ybr=(y+r)+((h)-(2*r))
--bottom right mid circle
local xbl=(x+r)
local ybl=(y+r)+((h)-(2*r))
-----------------------------
cairo_move_to (cr,xtl,ytl-r)
cairo_line_to (cr,xtr,ytr-r)
cairo_arc(cr,xtr,ytr,r,((2*math.pi/4)*3),((2*math.pi/4)*4))
cairo_line_to (cr,xbr+r,ybr)
cairo_arc(cr,xbr,ybr,r,((2*math.pi/4)*4),((2*math.pi/4)*1))
cairo_line_to (cr,xbl,ybl+r)
cairo_arc(cr,xbl,ybl,r,((2*math.pi/4)*1),((2*math.pi/4)*2))
cairo_line_to (cr,xtl-r,ytl)
cairo_arc(cr,xtl,ytl,r,((2*math.pi/4)*2),((2*math.pi/4)*3))
cairo_close_path(cr)
cairo_fill (cr)
------------------------------------------------------------
cairo_surface_destroy(cs)
cairo_destroy(cr)
return ""
end

Last edited by ackernan (2011-08-11 11:14:46)

Offline

#2560 2011-08-11 20:23:21

xeNULL
#! Pirate
From: The Internet
Registered: 2011-01-23
Posts: 811

Re: My Conky Config

A base conky for you guys to use big_smile

You will need the Terminus and Humanoid fonts.

minconky.png

#==============================================================================
#  MinHXR
#
#  Date    : 11/08/2011
#  author  : xeNULL
#  version : v0.1
#  license : Distributed under the terms of GNU GPL version 2 or later
#
#==============================================================================

background yes
update_interval 1

cpu_avg_samples 2
net_avg_samples 2
temperature_unit celsius
short_units yes

double_buffer yes
no_buffers yes
text_buffer_size 2048

gap_x 0
gap_y 10

minimum_size 500 35
maximum_width 500
own_window yes
own_window_type desktop
own_window_transparent yes
own_window_hints undecorate,sticky,skip_taskbar,skip_pager,below
border_inner_margin 0
border_outer_margin 0
alignment tm

draw_shades no
draw_outline no
draw_borders no
draw_graph_borders yes

default_bar_size 115 30

override_utf8_locale no
use_xft yes
xftfont Terminus:size=7
xftalpha 1.0
uppercase no

default_color FFFFFF ## white
color1 999999 ## Medium Grey
color2 510000 ## Dark Red


TEXT
${color2}${font Humanoid:size=9}o${font}${color} cpu 1 ${goto 50}${cpubar cpu0 5,80}  ${color2}${font Humanoid:size=9}o${font}${color}  disk ${goto 200}${fs_bar 5,80 /}  ${color2}${font Humanoid:size=9}o${font}${color}  ip ${goto 350}${addr wlan0}  ${offset 7}${color2}${font Humanoid:size=9}o${font}${color}
${color2}${font Humanoid:size=9}o${font}${color} cpu 2 ${goto 50}${cpubar cpu1 5,80}  ${color2}${font Humanoid:size=9}o${font}${color}  home ${goto 200}${fs_bar 5,80 /home/xn}  ${color2}${font Humanoid:size=9}o${font}${color}  up ${goto 350}${upspeedgraph wlan0 5,80}  ${color2}${font Humanoid:size=9}o${font}${color}
${color2}${font Humanoid:size=9}o${font}${color} mem ${goto 50}${membar 5,80}  ${color2}${font Humanoid:size=9}o${font}${color}  ehd  ${goto 200}${fs_bar 5,80 /media/XEHD}  ${color2}${font Humanoid:size=9}o${font}${color}  down ${goto 350}${upspeedgraph wlan0 5,80}  ${color2}${font Humanoid:size=9}o${font}${color}
${color2}${font Humanoid:size=9}o${font}${color} vol ${goto 50}${mixerbar 'PCM' 5,80}  ${color2}${font Humanoid:size=9}o${font}${color}  r/w  ${goto 200}${diskiograph 5,80}  ${color2}${font Humanoid:size=9}o${font}${color}  qual ${goto 350}${wireless_link_bar 5,80 wlan0}  ${color2}${font Humanoid:size=9}o${font}${color}

${if_running mocp}${alignc}${font sans:size=8}${exec mocp -Q %song}  ${color2}${font Humanoid:size=9}o${font}${color} ${exec mocp -Q %artist} ${color2}${font Humanoid:size=9}o${font}${color} ${exec mocp -Q %album}${font}${else}${endif}

AKA xii on #crunchbang #!WMFS2
dotshare | dA | 1 1 0 1 0 1 0 0 0

Offline

#2561 2011-08-11 20:51:58

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: My Conky Config

ackernan wrote:

I use a lua script to create my conky background.  Occasionally for no reason the background will disappear for few seconds, nothing else does.  How can I fix this?  It's nothing major, just annoying.

I'm at a loss on this, maybe mrpeachy or wlourf can help - unless there are other LUA gurus in the house.


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#2562 2011-08-11 20:54:47

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: My Conky Config

xeNULL wrote:

A base conky for you guys to use big_smile

You will need the Terminus and Humanoid fonts.

minconky.png

Look nice.  Or change the fonts  big_smile


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#2563 2011-08-11 22:16:00

wlourf
#! CrunchBanger
Registered: 2010-02-13
Posts: 153
Website

Re: My Conky Config

ackernan wrote:

I use a lua script to create my conky background.  Occasionally for no reason the background will disappear for few seconds, nothing else does.  How can I fix this?  It's nothing major, just annoying.

http://dl.dropbox.com/u/23122621/Selection_055.png

Try to run your conky in a terminal :

killall conky
conky -c /path/to/your/conkyrc

I guess you will get some errors when the background disappear, post them please .

Offline

#2564 2011-08-11 22:40:22

xeNULL
#! Pirate
From: The Internet
Registered: 2011-01-23
Posts: 811

Re: My Conky Config

Sector11 wrote:
xeNULL wrote:

A base conky for you guys to use big_smile

You will need the Terminus and Humanoid fonts.

minconky.png

Look nice.  Or change the fonts  big_smile

Or that lol


AKA xii on #crunchbang #!WMFS2
dotshare | dA | 1 1 0 1 0 1 0 0 0

Offline

#2565 2011-08-12 11:35:22

omns
#! wanderer
From: ~/
Registered: 2008-11-25
Posts: 5,131

Re: My Conky Config

Please now post your conky configs in the monthly conky threads smile

Offline

Board footer

Powered by FluxBB

Copyright © 2012 CrunchBang Linux.
Proudly powered by Debian. Hosted by Linode.
Debian is a registered trademark of Software in the Public Interest, Inc.
Server: acrobat

Debian Logo