Conky Showoff thread

Add functionality to your desktop
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
marcdilnutt

Re: Conky Showoff thread

Post by marcdilnutt »

Silly question, but how do I have multiple conkys running at the same time? For example how do I run one on the left and another on the right? Is it simply a matter of having two parts in the conkyrc file, one for each instance?
An example file would be fantastic help, if possible.
dawgdoc

Re: Conky Showoff thread

Post by dawgdoc »

marcdilnutt wrote:...but how do I have multiple conkys running at the same time? Is it simply a matter of having two parts in the conkyrc file, one for each instance?
An example file would be fantastic help, if possible.
You would need a separate conkyrc file for each; such as conkyrc conkyrc-1 conkyrc-2 etc
Then you can use the one startconky.sh script to start them all.

See THIS post from the previous page for an example.
marcdilnutt

Re: Conky Showoff thread

Post by marcdilnutt »

Nice one, thanks. I dont know how I missed that!
marcdilnutt

Re: Conky Showoff thread

Post by marcdilnutt »

Here is mine, it is based heavily on one from this thread, sorry but I cant remember your name, with bits and pieces of some others thrown in. I still need to tweak it a bit but I am getting there.

Image

Uploaded with ImageShack.us

Uploaded with ImageShack.us

Code: Select all

background yes
    use_xft yes
    xftfont HandelGotD:size=8
    xftalpha 0.5
    out_to_console no
    out_to_stderr no
    extra_newline no
    update_interval 1.0
    total_run_times 0
    own_window yes
    own_window_type override
    own_window_transparent yes
    own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager
    double_buffer yes
    minimum_size 170 5
    maximum_width 220
    draw_shades no
    draw_outline no
    draw_borders no
    draw_graph_borders yes
    uppercase no
    default_color ffffff
    alignment top_right
    gap_x 5
    gap_y 5
    no_buffers yes
    cpu_avg_samples 2
    override_utf8_locale no
    color1 FB9845
    color2 E86D27
    color5 red
    TEXT
         ${voffset 4}${font Openlogos:style=Bold:size=30}${alignr 20}${color 7CDB32}t ${voffset -10}${font formintElegance:style=Bold:size=24}${alignr 40}${color 7CDB32}Linux Mint 9
    ${color}${font} Kernel:  ${alignr 2}${sysname}${kernel}
            ${color}HostName: ${alignr 2}${nodename}
            Architecture: ${alignr}${machine}
    ${color}${font StyleBats:size=16}A${font}   CPU1: ${cpu cpu1}% ${alignr 2}${cpubar cpu1 8,60}
    ${color}${font StyleBats:size=16}A${font}   CPU2: ${cpu cpu2}% ${alignr 2}${cpubar cpu2 8,60 53ef0e}
    ${color}${font StyleBats:size=16}j${font}   SWAP: $swapperc% ${alignr 2}${swapbar 8,60 C34723}
    ${color}${font StyleBats:size=16}g${font}   RAM: $memperc% ${alignr 2}${membar 8,60 FB9845}
    ${color}${font StyleBats:size=16}K${color}${font}   Temp: ${alignr 2}${hwmon temp 1} C

    ${color}${font StyleBats:size=16}4${font}   /:  ${fs_used_perc /}% ${alignr 2}${fs_bar 8,60 /}
    ${color}${font StyleBats:size=16}4${font}   Home:  ${fs_used_perc /home}% ${alignr 2}${fs_bar 8,60 /home}
    ${color}${font StyleBats:size=16}4${font}   Docs:  ${fs_used_perc /home/marc/Documents}% ${alignr 2}${fs_bar 8,60 /home/marc/Documents}
    ${color}${font StyleBats:size=16}4${font}   Backup:  ${fs_used_perc /media/BACKUP}% ${alignr 2}${fs_bar 8,60 /media/BACKUP}
 
    ${color}${font StyleBats:size=16}q${font}   Uptime: ${alignr 2}${uptime}
    ${color}${font StyleBats:size=16}q${font}   Time: ${alignr 2}${color1}${time %H:%M:%S} ${color2}${time %d/%m/%y}
    ${if_existing /proc/net/route wlan0}
    ${color}${voffset 4}${font PizzaDude Bullets:size=14}a${font} Network: ${alignr 10}${wireless_essid wlan0}
    ${voffset 4}${font PizzaDude Bullets:size=14}Z${font} Signal: ${wireless_link_qual_perc wlan0}% ${alignr 2}${wireless_link_bar 8,60 wlan0}
    
    ${color}${voffset -6}${font PizzaDude Bullets:size=14}O${font}  Up: ${upspeed wlan0} ${color}${alignr 2}${upspeedgraph wlan0 8,60 C34723 FB9845}
    ${color}${voffset 4}${font PizzaDude Bullets:size=14}U${font}   Down: ${downspeed wlan0} ${color}${alignr 2}${downspeedgraph wlan0 8,60 C34723 FB9845}
    ${color}${voffset 4}${font PizzaDude Bullets:size=14}N${font}   Upload: ${alignr 2}${totalup wlan0}
    ${color}${voffset 4}${font PizzaDude Bullets:size=14}T${font}   Download: ${alignr 2}${totaldown wlan0}
    ${color}${voffset 4}${font PizzaDude Bullets:size=14}a${font}   Local Ip: ${alignr 2}${addr wlan0}
User avatar
mintmaniac2
Level 4
Level 4
Posts: 219
Joined: Wed May 27, 2009 1:10 pm
Location: Somewhere on the Internet. Probably

Re: Conky Showoff thread

Post by mintmaniac2 »

marcdilnutt, that would be me. Nice to see some of my work used by others. It's a nice feeling, esp after borrowing lots of stuff from other people.
Image
sudo apt-get purge win7 && sudo apt-get install Freedom
You're currently going through a difficult transition period called "Life."
marcdilnutt

Re: Conky Showoff thread

Post by marcdilnutt »

mintmaniac - Thanks, it was a real help to have a good solid backbone to work from while trying things out. I am running it on a netbook so space is at a premium, I am still fiddling with it to get all the info I want in the space that I have.
Monarch

Re: Conky Showoff thread

Post by Monarch »

This is my Conky it requires some Extra FONTS
link to where u should get them below

http://gnome-look.org/content/show.php/ ... ent=120785

how it looks like

Image

Code: Select all

# Use Xft?
use_xft yes
xftfont DejaVu Sans:size=8
xftalpha 0.8
text_buffer_size 2048

# Update interval in seconds
update_interval 1

# This is the number of times Conky will update before quitting.
# Set to zero to run forever.
total_run_times 0

# Create own window instead of using desktop (required in nautilus)
own_window yes
own_window_transparent yes
own_window_type override
#KDE Below
#own_window_type normal
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager

# Use double buffering (reduces flicker, may not work for everyone)
double_buffer yes

# Minimum size of text area
minimum_size 180 0
#maximum_width 200

# Draw shades?
draw_shades yes

# Draw outlines?
draw_outline yes

# Draw borders around text
draw_borders no

# Stippled borders?
stippled_borders 0

# border margins
#border_margin 5

# border width
border_width 1

# Default colors and also border colors
#default_color B7EA81
#default_shade_color black
#default_outline_color white
own_window_colour transparent
#this is your color pallete
color0	ffffff	#white
color1	00ff00	#green${voffset 8}$
color2	0000ff	#blue
color3	ff0000	#red
color4	7da8f8	#wierd blue
color5	496291	#azul mas oscuro
color6  B7EA81  #great green


# Text alignment, other possible values are commented
#alignment top_left
alignment top_right
#alignment bottom_left
#alignment bottom_right

# Gap between borders of screen and text
# same thing as passing -x at command line
gap_x 10
gap_y 30

# Subtract file system buffers from used memory?
no_buffers yes

# set to yes if you want all text to be in uppercase
uppercase no

# number of cpu samples to average
# set to 1 to disable averaging
cpu_avg_samples 2

# number of net samples to average
# set to 1 to disable averaging
net_avg_samples 2

# Force UTF8? note that UTF8 support required XFT
override_utf8_locale yes

# Add spaces to keep things from moving about?  This only affects certain objects.
use_spacer none
draw_graph_borders yes
TEXT
${offset 33}${color1}${font INFECTED:size=20}hardcore
${voffset -10}${offset 14}${color6}${font Defused::bold:size=10}${kernel}
${voffset 5}${color2}${font Defused:size=8}Uptime: ${alignr}${color3}${uptime}

${color5}CPU0: ${offset 6}${color0}${cpu cpu0}% ${offset -6}${alignr}
${color6}${cpugraph cpu1 15,100 00FF00 FF0000}

${voffset 3}${color5}RAM: ${offset 12}${color0}$memperc% ${offset -12}${alignr}
${color6}${memgraph 15,100 00FF00 FF0000}

${voffset 8}${color2}${font Defused:size=10}Home:
${voffset 3}${color1}${font Defused:size=10}${fs_free /home}/${fs_size /home} 


${voffset 3}${color6}${fs_bar 10,180 /home}
${offset 10}${color1}${font INFECTED:size=17}TOP CPU${font}
${color6}${voffset 10}${font JUICE Bold:size=8}${top name 1}${alignr}${top cpu 1}
${top name 2}${alignr}${top cpu 2}
${top name 3}${alignr}${top cpu 3}
${top name 4}${alignr}${top cpu 4}
${top name 5}${alignr}${top cpu 5}
${offset }${color1}${font INFECTED:size=17}TOP MEM${font}
${color6}${voffset 10}${font JUICE Bold:size=8}${top_mem name 1}${alignr}${top_mem mem 1}
${top_mem name 2}${alignr}${top_mem mem 2}
${top_mem name 3}${alignr}${top_mem mem 3}
${top_mem name 4}${alignr}${top_mem mem 4}
${top_mem name 5}${alignr}${top_mem mem 5}

${color1}${voffset 10}${offset 37}${font INFECTED:size=17}NETWORK
${color2}${voffset -10}${color1}${font Defused:size=7}Down: 
${color6}${downspeedgraph eth1 20,110 0000FF 00FF00}${voffset -15}${alignr}${color0}${downspeed eth1} 


${color3}${font Defused:size=7}Up:  
${color6}${upspeedgraph eth1 20,110 FF0000 008000}${voffset -15}${alignr}${color0}${upspeed eth1}

${color6}${voffset 10}${font Defused:size=10}${wireless_essid eth1}

${color6}${voffset 10}${font Defused:size=10}Local Ip: ${alignr}${color1}${addr eth1}

${color6}${voffset 10}Potencia:${alignr}${color2}${wireless_link_qual_perc eth1}

${color6}${voffset 10}Velocidad: ${color0}${wireless_bitrate eth1} ${alignr}${voffset -10}





red-e-made
Level 5
Level 5
Posts: 526
Joined: Sat Jul 14, 2007 11:31 am

Re: Conky Showoff thread

Post by red-e-made »

For the few of you who might be interested, there's a tiny little (1.1Kb) script you can run which will display the phase of the moon in Conky without having to install conkyForecasts.

First, create an executable file in home/[user name] and name it moon.py

The script is as follows - the original did not have the "Lunar Phase:" there:

Code: Select all

#!/usr/bin/env python
"""
moonphase.py - Calculate Lunar Phase
Author: Sean B. Palmer, inamidst.com
Cf. http://en.wikipedia.org/wiki/Lunar_phase#Lunar_phase_calculation
"""

import math, decimal, datetime
dec = decimal.Decimal

def position(now=None): 
   if now is None: 
      now = datetime.datetime.now()

   diff = now - datetime.datetime(2001, 1, 1)
   days = dec(diff.days) + (dec(diff.seconds) / dec(86400))
   lunations = dec("0.20439731") + (days * dec("0.03386319269"))

   return lunations % dec(1)

def phase(pos): 
   index = (pos * dec(8)) + dec("0.5")
   index = math.floor(index)
   return {
      0: "Lunar Phase: New Moon", 
      1: "Lunar Phase: Waxing Crescent", 
      2: "Lunar Phase: First Quarter", 
      3: "Lunar Phase: Waxing Gibbous", 
      4: "Lunar Phase: Full Moon", 
      5: "Lunar Phase: Waning Gibbous", 
      6: "Lunar Phase: Last Quarter", 
      7: "Lunar Phase: Waning Crescent"
   }[int(index) & 7]

def main(): 
   pos = position()
   phasename = phase(pos)

   roundedpos = round(float(pos), 3)
   print "%s (%s)" % (phasename, roundedpos)

if __name__=="__main__": 
   main()
Add the following line to Conky:

Code: Select all

${exec python moon.py}
And you're done.

The output will display e.g.

Code: Select all

Lunar Phase: First Quarter (0.272)
That last figure indicates fullness, with 1.0 of course being a full moon. As you can see, this moon brightness is calculated into the thousandths, and datetime.datetime calculates time to the microsecond, so you could change the Conky command to e.g.

Code: Select all

${execi 5 python moon.py}
... and get moon brightness updates every five seconds! OK, maybe you don't want updates that often, but the phase does increase in brightness every few minutes, I've seen; the moon's a fast-moving object.

EDIT: Guess I might as well show my Conky here then. Click for fullsize:

Image

I do not use conkyForecast, as last I checked this required adding Ubuntu repositories, and I'm running LMDE. So instead I installed Debian's weather.util package. Apart from the moon.py script, I also use a .conky_start.sh script that delays Conky's start by 20 seconds - in this way, the desktop is fully loaded when Conky turns on, and there are no rendering problems. The code for the .conky_start.sh script is simple enough:

Code: Select all

#!/bin/bash
sleep 20 && conky
Then I change the Conky command in Startup Applications to sh .conky_start.sh - easy peasy!

And this is my .conkyrc:

Code: Select all

#avoid flicker
double_buffer yes

#own window to run simultanious 2 or more conkys
own_window  yes
own_window_transparent yes
own_window_type normal
own_window_hints undecorate,sticky,skip_taskbar,skip_pager 

#borders
draw_borders no
border_margin 0

#shades
draw_shades no

#position
gap_x 5
gap_y 40
alignment top_right

#behaviour
update_interval 1

#colour
default_color  e0e0e0
#default_shade_color 242424
own_window_colour 000000

#font
use_xft yes
xftfont sans:size=8

# Force UTF8? note that UTF8 support required  UFT
override_utf8_locale yes

#to prevent window from moving
use_spacer no
minimum_size 200 0

#mpd
#mpd_host localhost
#mpd_port 6600

TEXT
${alignr}${time %H:%M:%S}    ${alignr}${time %a %d %b %Y}

${alignr}Kernel: $kernel
${alignr}Distro: Linux Mint Debian

${alignr}Memory: $mem / $memmax
${alignr}RAM: ${memperc}%
${alignr}CPU1: ${cpu cpu1}%    CPU2: ${cpu cpu2}%
${alignr}Temp: ${nvidia temp}°C

${alignr}           TOP              CPU%    MEM%
${alignr}${top name 1} ${top cpu 1}      ${top mem 1}
${alignr}${top name 2} ${top cpu 2}      ${top mem 2}
${alignr}${top name 3} ${top cpu 3}      ${top mem 3}
${alignr}${top name 4} ${top cpu 4}      ${top mem 4}
${alignr}${top name 5} ${top cpu 5}      ${top mem 5}
${alignr}${top name 6} ${top cpu 6}      ${top mem 6}
${alignr}${top name 7} ${top cpu 7}      ${top mem 7}
${alignr}${top name 8} ${top cpu 8}      ${top mem 8}
${alignr}${top name 9} ${top cpu 9}      ${top mem 9}

${alignr}File System:  Free:${fs_free /}
${alignr}              Used:${fs_used /}
${alignr}Home:  Free:${fs_free /home}
${alignr}       Used:${fs_used /home}
${alignr}Data:  Free:${fs_free /home/[me]/Desktop/Data}
${alignr}       Used:${fs_used /home/[me]/Desktop/Data}

${alignr}${execi 5 weather -i BIRK -q -m}

${alignr}${execi 5 python moon.py}
Aging Technogeek

Re: Conky Showoff thread

Post by Aging Technogeek »

I put this together recently. Thought I'd share it.

Image

Here's the .conkyrc

Code: Select all

# MINT-CONKY
# A comprehensive conky script, configured for use on
# MINT, without the need for any external scripts.
#
# Based on conky-jc and the default .conkyrc.
# INCLUDES:
# - tail of /var/log/messages
# - netstat connections to your computer
#

# Create own window instead of using desktop (required in nautilus)
own_window yes
own_window_type normal
own_window_transparent yes
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager

# Use double buffering (reduces flicker, may not work for everyone)
double_buffer yes

# fiddle with window
use_spacer yes
use_xft no

# Update interval in seconds
update_interval 2.0

# Minimum size of text area
# minimum_size 250 4

minimum_size 350
maximum_width 280

# Draw shades?
draw_shades no

# Text stuff
draw_outline no
# amplifies text if yes
draw_borders no
# font sans
uppercase no
# set to yes if you want all text to be in uppercase

# Stippled borders?
stippled_borders 3

# border margins
border_margin 5

# border width
border_width 2b0

# Default colors and also border colors, grey90 == #e5e5e5
default_color white

own_window_colour black
own_window_transparent yes

# Text alignment, other possible values are commented
#alignment top_left
alignment top_right
#alignment bottom_left
#alignment bottom_right

# Gap between borders of screen and text
gap_x 15
gap_y 150

# Antialiased Fonts
# use_xft
# xftfont Sans
# font size 4

# stuff after 'TEXT' will be formatted on screen

TEXT
$color
${color green}SYSTEM ${hr 2}$color

$alignc Mint 9 Gnome running on ${nodename}
$alignc Kernel: ${kernel}
$alignc Uptime: ${uptime}

${color green}CPU ${hr 2}$color

Usage: ${cpu}% of ${freq} MHz $alignr${cpubar 6,120}

${cpugraph 25,280 000000 00bd00}

${color green}PROCESSES ${hr 2}${color}

NAME             PID       CPU%      MEM%
${color a2a2a2}${hr}$color
${top name 1} ${top pid 1}   ${top cpu 1}    ${top mem 1}
${top name 2} ${top pid 2}   ${top cpu 2}    ${top mem 2}
${top name 3} ${top pid 3}   ${top cpu 3}    ${top mem 3}
${top name 4} ${top pid 4}   ${top cpu 4}    ${top mem 4}
${top name 5} ${top pid 5}   ${top cpu 5}    ${top mem 5}

${color green}MEMORY ${hr 2}$color

Memory     used ${mem} of ${memmax}

RAM $memperc % ${membar 6,60}$color ${alignr}Swap $swapperc%   ${swapbar 6,60}$color

$alignr${memgraph 25,280 3d3400 cdae00}

${color green}DISK ${hr 2}$color

Root:   ${fs_used_perc /}%${alignr}${color bd0000}${fs_bar 6,195 /}$color4
Home:   ${fs_used_perc /home}%${alignr}${color 0000bd}${fs_bar 6,195 /home}$color
Data:   ${fs_used_perc /media/Data}%${alignr}${color 00bd00}${fs_bar 6,195 /media/Data}$color

${color green}NETWORK (${addr eth0}) ${hr 2}$color

$Down: $color${downspeed eth0} k/s ${alignr}Up: ${upspeed eth0} k/s   
$color${downspeedgraph eth0 25,135 000000 bd0000} ${alignr}${upspeedgraph 
eth0 25,135 000000 0000bd}       $color
Total: ${color a2a2a2}${totaldown eth0}${color }${alignr}Total: ${color a2a2a2}${totalup eth0}  $color

# Inbound: ${tcp_portmon 1 32767 count}    Outbound: ${tcp_portmon 32768 61000 count}${alignr}    Ttorrent: ${tcp_portmon 6881 6999 count}
# Total: ${tcp_portmon 1 65535 count} 
Hope you like it.
User avatar
KittyKatt
Level 3
Level 3
Posts: 116
Joined: Sun Jun 14, 2009 12:12 pm
Contact:

Re: Conky Showoff thread

Post by KittyKatt »

Okay, so this isn't on my Mint install, but I thought I would go ahead and show it off anyways.

Click for full-size screenshot...
Image

All my configs can be found at http://git.silverirc.com/cgit.cgi/kitty ... .git/tree/

The ismount.sh I use to output FS info is really hacky and needs some work. I just wrote it up about an hour ago to replace a python one I had before, which is now broken due to python3. Also note that the repositories section will not work on your machine unless you're also using Arch Linux as I am in this screenshot. :D

Enjoy.
zerozero

Re: Conky Showoff thread

Post by zerozero »

Still a work in progress, but i'm happier with it now,

conkyrc:

Code: Select all

# -- Conky settings -- #
background no
update_interval 1
 
cpu_avg_samples 2
net_avg_samples 2
 
override_utf8_locale yes
 
double_buffer yes
no_buffers yes
 
text_buffer_size 2048
imlib_cache_size 0
 
#Window settings
own_window yes
own_window_type override no
own_window_transparent yes
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager

 
border_inner_margin 0
border_outer_margin 0
 
minimum_size 1320 150
maximum_width 1320
 
alignment tm
gap_x 10
gap_y 40
 
# -- Graphics settings -- #
draw_shades no
draw_outline no
draw_borders no
draw_graph_borders no
 
# -- Text settings -- #
use_xft yes
xftfont Droid Sans:size=16
xftalpha 0.6
 
uppercase no
 
default_color 666666
 
# -- Lua Load -- #
lua_load ~/scripts/rings-lua
lua_draw_hook_pre ring_stats
 
TEXT

${voffset 35}${goto 40}${uptime_short}${voffset -35}${goto 170}ds ${downspeed eth2}${goto 300}us ${upspeed eth2}${goto 420}cpu ${acpitemp}C (${cpu cpu0}% ${cpu cpu1}%)${goto 620}${color ff00ff}ram ${memperc}% ${color}${goto 730}proc ${processes} (${running_processes} run)${goto 950}fs ${fs_used /}(${fs_used_perc /}%)${goto 1230}
${goto 165}${color ff00ff}${hr 1}${color}
${goto 900}${time %A, %d %B %Y} 

rings-lua (a heavily modified version of Londonali's rings):

Code: Select all

--[[
Ring Meters by londonali1010 (2009)
 
This script draws percentage meters as rings. It is fully customisable; all options are described in the script.
 
IMPORTANT: if you are using the 'cpu' function, it will cause a segmentation fault if it tries to draw a ring straight away. The if statement on line 145 uses a delay to make sure that this doesn't happen. It calculates the length of the delay by the number of updates since Conky started. Generally, a value of 5s is long enough, so if you update Conky every 1s, use update_num > 5 in that if statement (the default). If you only update Conky every 2s, you should change it to update_num > 3; conversely if you update Conky every 0.5s, you should use update_num > 10. ALSO, if you change your Conky, is it best to use "killall conky; conky" to update it, otherwise the update_num will not be reset and you will get an error.
 
To call this script in Conky, use the following (assuming that you save this script to ~/scripts/rings.lua):
	lua_load ~/scripts/rings-v1.2.1.lua
	lua_draw_hook_pre ring_stats
 
Changelog:
+ v1.2.1 -- Fixed minor bug that caused script to crash if conky_parse() returns a nil value (20.10.2009)
+ v1.2 -- Added option for the ending angle of the rings (07.10.2009)
+ v1.1 -- Added options for the starting angle of the rings, and added the "max" variable, to allow for variables that output a numerical value rather than a percentage (29.09.2009)
+ v1.0 -- Original release (28.09.2009)
]]
 
settings_table = {
	{
		-- Edit this table to customise your rings.
		-- You can create more rings simply by adding more elements to settings_table.
		-- "name" is the type of stat to display; you can choose from 'cpu', 'memperc', 'fs_used_perc', 'battery_used_perc'.
		name='time',
		-- "arg" is the argument to the stat type, e.g. if in Conky you would write ${cpu cpu0}, 'cpu0' would be the argument. If you would not use an argument in the Conky variable, use ''.
		arg='%I.%M',
		-- "max" is the maximum value of the ring. If the Conky variable outputs a percentage, use 100.
		max=12,
		-- "bg_colour" is the colour of the base ring.
		bg_colour=0xffffff,
		-- "bg_alpha" is the alpha value of the base ring.
		bg_alpha=0.1,
		-- "fg_colour" is the colour of the indicator part of the ring.
		fg_colour=0xffffff,
		-- "fg_alpha" is the alpha value of the indicator part of the ring.
		fg_alpha=0.4,
		-- "x" and "y" are the x and y coordinates of the centre of the ring, relative to the top left corner of the Conky window.
		x=75, y=75,
		-- "radius" is the radius of the ring.
		radius=50,
		-- "thickness" is the thickness of the ring, centred around the radius.
		thickness=5,
		-- "start_angle" is the starting angle of the ring, in degrees, clockwise from top. Value can be either positive or negative.
		start_angle=0,
		-- "end_angle" is the ending angle of the ring, in degrees, clockwise from top. Value can be either positive or negative, but must be larger (e.g. more clockwise) than start_angle.
		end_angle=360
	},
	{
		name='time',
		arg='%M',
		max=60,
		bg_colour=0xffffff,
		bg_alpha=0.1,
		fg_colour=0xffffff,
		fg_alpha=0.4,
		x=75, y=75,
		radius=56,
		thickness=5,
		start_angle=0,
		end_angle=360
	},
	{
		name='time',
		arg='%S',
		max=60,
		bg_colour=0xffffff,
		bg_alpha=0.1,
		fg_colour=0xff0000,
		fg_alpha=0.8,
		x=75, y=75,
		radius=62,
		thickness=5,
		start_angle=0,
		end_angle=360
	},
	{
		name='loadavg',
		arg='1',
		max=1,
		bg_colour=0xffffff,
		bg_alpha=0.1,
		fg_colour=0xff0000,
		fg_alpha=0.8,
		x=1250, y=75,
		radius=62,
		thickness=5,
		start_angle=0,
		end_angle=360
	},
	{
		name='loadavg',
		arg='2',
		max=1,
		bg_colour=0xffffff,
		bg_alpha=0.1,
		fg_colour=0xff0000,
		fg_alpha=0.8,
		x=1250, y=75,
		radius=56,
		thickness=5,
		start_angle=0,
		end_angle=360
	},
	{
		name='loadavg',
		arg='3',
		max=1,
		bg_colour=0xffffff,
		bg_alpha=0.1,
		fg_colour=0xff0000,
		fg_alpha=0.8,
		x=1250, y=75,
		radius=50,
		thickness=5,
		start_angle=0,
		end_angle=360
	},	
}
 
require 'cairo'
 
function rgb_to_r_g_b(colour,alpha)
	return ((colour / 0x10000) % 0x100) / 255., ((colour / 0x100) % 0x100) / 255., (colour % 0x100) / 255., alpha
end
 
function draw_ring(cr,t,pt)
	local w,h=conky_window.width,conky_window.height
 
	local xc,yc,ring_r,ring_w,sa,ea=pt['x'],pt['y'],pt['radius'],pt['thickness'],pt['start_angle'],pt['end_angle']
	local bgc, bga, fgc, fga=pt['bg_colour'], pt['bg_alpha'], pt['fg_colour'], pt['fg_alpha']
 
	local angle_0=sa*(2*math.pi/360)-math.pi/2
	local angle_f=ea*(2*math.pi/360)-math.pi/2
	local t_arc=t*(angle_f-angle_0)
 
	-- Draw background ring
 
	cairo_arc(cr,xc,yc,ring_r,angle_0,angle_f)
	cairo_set_source_rgba(cr,rgb_to_r_g_b(bgc,bga))
	cairo_set_line_width(cr,ring_w)
	cairo_stroke(cr)
 
	-- Draw indicator ring
 
	cairo_arc(cr,xc,yc,ring_r,angle_0,angle_0+t_arc)
	cairo_set_source_rgba(cr,rgb_to_r_g_b(fgc,fga))
	cairo_stroke(cr)		
end
 
function conky_ring_stats()
	local function setup_rings(cr,pt)
		local str=''
		local value=0
 
		str=string.format('${%s %s}',pt['name'],pt['arg'])
		str=conky_parse(str)
 
		value=tonumber(str)
		if value == nil then value = 0 end
		pct=value/pt['max']
 
		draw_ring(cr,pct,pt)
	end
 
	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 cr=cairo_create(cs)	
 
	local updates=conky_parse('${updates}')
	update_num=tonumber(updates)
 
	if update_num>5 then
		for i in pairs(settings_table) do
			setup_rings(cr,settings_table[i])
		end
	end
end
User avatar
mintmaniac2
Level 4
Level 4
Posts: 219
Joined: Wed May 27, 2009 1:10 pm
Location: Somewhere on the Internet. Probably

Re: Conky Showoff thread

Post by mintmaniac2 »

To call the conkyForecast, what do you put in the .conkyrc file? is it something along the lines of ${execi 300 ~/conkyForecast}, or do i have completely the wrong idea here. help me out please.
Image
sudo apt-get purge win7 && sudo apt-get install Freedom
You're currently going through a difficult transition period called "Life."
User avatar
KittyKatt
Level 3
Level 3
Posts: 116
Joined: Sun Jun 14, 2009 12:12 pm
Contact:

Re: Conky Showoff thread

Post by KittyKatt »

mintmaniac2 wrote:To call the conkyForecast, what do you put in the .conkyrc file? is it something along the lines of ${execi 300 ~/conkyForecast}, or do i have completely the wrong idea here. help me out please.
You could call it using ${execpi 300 /path/to/conkyForecast /path/to/conkyForecastconfigfile}
chi-kitory

Re: Conky Showoff thread

Post by chi-kitory »

Image

Code: Select all

# conky configuration
##############################################
#  Settings
##############################################
background no
use_xft yes
xftfont Sans:size=8
xftalpha 1
update_interval 1.0
total_run_times 0
own_window yes
own_window_class Conky
own_window_transparent yes
own_window_type normal
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager
double_buffer yes
minimum_size 200 200
maximum_width 240
draw_shades no
draw_outline no
draw_borders no
draw_graph_borders no
stippled_borders 0
default_color white
default_shade_color grey
default_outline_color white
alignment top_right
gap_x 8
gap_y 34
no_buffers yes
uppercase no
cpu_avg_samples 2
override_utf8_locale no
color0 white  #same as default color
color1 FCFF69 #Exaile detail text
color2 CCE6FF #bar color
color3 DAFFB3  #exaile cat color
color4 CCFFCC #section header color
color5 FFFF66 #Time color
##############################################
#  Output
##############################################
TEXT
${color4}${font Sans:bold:size=8}DATE ${hr 2}${font}

${color2}${alignc 19}${font Trebuchet MS:size=15}${time %I:%M%p}${font}
${color2}${voffset 6}${alignc}${time %A, %d %B %Y}

${color4}${font Sans:bold:size=8}SYSTEM INFO ${hr 2}
${font}
${alignc}${font formintElegance:size=15}Mint Fluxbox 9 ${font}
${color0}System:$alignr$sysname $machine
Kernel:$alignr$kernel
Host:$alignr$nodename

CPU Freq: ${alignr}${freq_g} GHz Intel Pentium 4 
${color0}CPU1: ${color FFFF99}${alignr}${cpu cpu1}% ${color2}${cpubar 8,90 cpu1}
${color0}CPU2: ${color FFFF99}${alignr}${cpu cpu2}% ${color2}${cpubar 8,90 cpu2}

${color0}Memory: $alignc $mem / $memmax $alignr $memperc%
${color2}${membar}

${color4}${font Sans:bold:size=8}HARD DRIVES ${hr 2}${font}
${color0}${voffset 4}Root: ${fs_used_perc /}%${alignr}${fs_free /} / ${fs_size /}
${color0}${voffset 4}Mydata: ${fs_used_perc /}%${alignr}${fs_free /media/mydata} / ${fs_size /media/mydata}

${color4}${font Sans:bold:size=8}PROCESSES ${hr 2}
${font Sans:size=7}
${color0}NAME             ${goto 110}PID${goto 138}CPU%${goto 175}MEM%${color FFFF99}
${top name 1}    ${goto 105}${top pid 1}${goto 138}${top cpu 1}${goto 175}${top mem 1}
${top name 2}    ${goto 105}${top pid 2}${goto 138}${top cpu 2}${goto 175}${top mem 2}
${top name 3}    ${goto 105}${top pid 3}${goto 138}${top cpu 3}${goto 175}${top mem 3}
${top name 4}    ${goto 105}${top pid 4}${goto 138}${top cpu 4}${goto 175}${top mem 4}
${top name 5}    ${goto 105}${top pid 5}${goto 138}${top cpu 5}${goto 175}${top mem 5}
${top name 6}    ${goto 105}${top pid 6}${goto 138}${top cpu 6}${goto 175}${top mem 6}
${font}

${color4}${font Sans:bold:size=8}Assignments ${hr 2}
${color2}${font formintElegance:size=7}US History Oral Report${font}
${color2}${font formintElegance:size=7}Read Pages 1024 in USP2${font}
${color2}${font formintElegance:size=7}Test on Monday (CHM)${font}
${color2}${font formintElegance:size=7}Sign-up for Classes${font}
under assignments your going to have to add your own. i am going to figure out a way so it reads from a txt file. but until then i guess ill just edit my conky.conf

Image
deadguy
Level 5
Level 5
Posts: 707
Joined: Wed Aug 15, 2007 9:41 pm
Location: Illinois USA

Re: Conky Showoff thread

Post by deadguy »

well, I finally decided to try conky! it's pretty cool...
think I'll put it on my laptop that runs LMDE next :)

Image

Image



.conkyrc:

Code: Select all

double_buffer yes
update_interval 3.0
background yes

own_window yes
own_window_transparent yes
own_window_hints undecorated,below,skip_taskbar

use_xft yes
override_utf8_locale no

xftfont Times New Roman:bold:size=9
xftalpha 0.8
draw_shades yes
draw_outline no
draw_borders no
uppercase yes
use_spacer none

border_width 0

default_color green
default_shade_color black
default_outline_color black

alignment top_right
minimum_size 200
gap_x 9
gap_y 9

TEXT
${color white}${font Times New Roman:bold:size=14}${alignc}${time %I:%M %p}, ${time %a}., ${time %b. %e}, ${time %G}
${color}${font Times New Roman:bold:size=12}${alignc}Arch Linux $kernel
${font Times New Roman:bold:size=12}${alignc}hostname: "$nodename" at ${addr eth0}
${font Times New Roman:bold:size=10}${alignc}$uptime uptime
${alignc}Weather: ${execi 300 /home/deadguy/conkyscripts/weather.sh 61081}
${font Times New Roman:size=10}${color darkblue}CPU: ${hr 2}
${font Times New Roman:bold:size=10}
${color orange}CPU0 Load: ${alignr}${cpu cpu0}%
${color red}${cpubar 20,200 000000 ff0000}${color}
Load averages: ${alignr}$loadavg

${color orange}CPU1 Load: ${alignr}${cpu cpu1}%
${color red}${cpubar 20,200 000000 ff0000}${color}
Load averages: ${alignr}$loadavg

${color pink}Processes: ${alignr}$running_processes of $processes running

${font Times New Roman:size=10}${color darkblue}Highest CPU usage: ${hr 2}
${font}${color red} ${top name 1}${alignr}${top cpu 1}
${color}${top name 2}${alignr}${top cpu 2}
${top name 3}${alignr}${top cpu 3}
${top name 4}${alignr}${top cpu 4}

${font Times New Roman:size=10}${color darkblue}Highest memory usage: ${hr 2}
${font}${color red} ${top_mem name 1}${alignr}${top_mem mem 1}
${color}${top_mem name 2}${alignr}${top_mem mem 2}
${top_mem name 3}${alignr}${top_mem mem 3}
${top_mem name 4}${alignr}${top_mem mem 4}

${font Times New Roman:size=10}${color darkblue}RAM: ${hr 2}
${font}${color}Memory usage: ${alignr}${memperc}% (${mem}b/${memmax}b)
${membar 3,200}

Swap usage: ${alignr}${swapperc}% (${swap}b/${swapmax}b)
${swapbar 3,200}

${font Times New Roman:size=10}${color darkblue}HDD: ${hr 2}
${font}${color}/ free: ${alignr}${fs_free_perc /}% (${fs_free /}b/${fs_size /}b)
${fs_bar 3,200 /}

/Home free: ${alignr}${fs_free_perc /home/deadguy}% (${fs_free /home/deadguy}b/${fs_size /home/deadguy}b)
${fs_bar 3,200 /home/deadguy}

Storage free: ${alignr}${fs_free_perc /home/deadguy/storage}% (${fs_free /home/deadguy/storage}b/${fs_size /home/deadguy/storage}b)
${fs_bar 3,200 /home/deadguy/storage}

Storage2TB free: ${alignr}${fs_free_perc /home/deadguy/storage2TB}% (${fs_free /home/deadguy/storage2TB}b/${fs_size /home/deadguy/storage2TB}b)
${fs_bar 3,200 /home/deadguy/storage2TB}

Storage3 free: ${alignr}${fs_free_perc /home/deadguy/storage3}% (${fs_free /home/deadguy/storage3}b/${fs_size /home/deadguy/storage3}b)
${fs_bar 3,200 /home/deadguy/storage3}

Xdrive free: ${alignr}${fs_free_perc /home/deadguy/xdrive300}% (${fs_free /home/deadguy/xdrive300}b/${fs_size /home/deadguy/xdrive300}b)
${fs_bar 3,200 /home/deadguy/xdrive300}

${font Times New Roman:size=10}${color darkblue}NET: ${hr 2}
${font}${color}Up:${alignr}${upspeed eth0}Kbps, ${totalup eth0}b total
${upspeedgraph eth0 10,200 000000 ffffff}
Down: ${alignr}${downspeed eth0}Kbps, ${totaldown eth0}b total
${downspeedgraph eth0 10,200 000000 fffff}
meskarune

Re: Conky Showoff thread

Post by meskarune »

Image

Calendar script: https://github.com/meskarune/.scripts

Conky:

Code: Select all

alignment top_left
background no
gap_x 10
gap_y 15
minimum_size 200 5
maximum_width 200

update_interval 1
total_run_times 0
double_buffer yes
no_buffers yes
text_buffer_size 1248

cpu_avg_samples 2
net_avg_samples 2

use_xft yes
xftfont HanelGotD:size=9
xftalpha 0.5
override_utf8_locale yes

own_window yes
own_window_type desktop
own_window_transparent yes
own_window_hints below,undecorated,sticky,skip_taskbar,skip_pager

draw_shades no
draw_outline no
draw_borders no
draw_graph_borders no

default_color 86b5ea
default_outline_color green

TEXT

${offset 4}${voffset -3}${color ffffff}${font URW Gothic L:size=60}${time %I}
${offset 100}${voffset -125}${color ffffff}${font URW Gothic L:size=32}${time :%M}
${offset 165}${voffset -73}${color #9ebcd7}${font URW Gothic L:size=13}${time %S}${color}
${offset 165}${voffset -7}${color ffffff}${font URW Gothic L:size=13}${time :%P}${color}

${font Liberation Mono:normal:size=12}${execpi 300 ~/.scripts/calendar.sh}

 ${color ffffff}${font ConkyWeather:size=55}${execi 600 conkyForecast --location=USOH0722 --datatype=WF}${font Liberation Mono:size=32} ${voffset -15}${execi 600 conkyForecast --location=USOH0722 --imperial --hideunits --datatype=HT}${font}${color}

${alignc}${font URW Gothic L:bold:size=10}${execi 600 conkyForecast --location=USOH0722 --datatype=CT}    ${execi 3600 conkyForecast --location=USOH0722 --datatype=HT --imperial --hideunits --startday=0 --endday=0}/ ${execi 3600 conkyForecast --location=USOH0722 --datatype=LT --imperial --hideunits --startday=0 --endday=0}${font}   

${color lightgrey}${font URW Gothic L:size=10}${execi 600 conkyForecast --location=USOH0722  --datatype=PC --startday=0 --endday=0} chance of precipitation

${execi 600 conkyForecast --location=USOH0722  --datatype=HM} humidity  ${alignr}Wind ${execi 600 conkyForecast --location=USOH0722  --imperial --startday=0 --datatype=WS}
${execi 600 conkyForecast --location=USOH0722  --datatype=BD} pressure  ${alignr 10}${execi 600 conkyForecast --location=USOH0722  --imperial --hideunits --startday=0 --datatype=WD}

${font Moon Phases:size=20}${execi 3600 conkyForecast --location=USOH0722 --datatype=MF} ${font}${font URW Gothic L:bold:size=10}${voffset -10}${execi 3600 conkyForecast --location=USOH0722 --datatype=MP}${font}

${font URW Gothic L:size=10}${alignc 10}Sunrise ${execi 600 conkyForecast --location=USOH0722 --startday=0 --datatype=SR}
chi-kitory

Re: Conky Showoff thread

Post by chi-kitory »

looks great meskarune. Inspires me to make a purple theme. Maybe one day i shall
I_can_see_the_light

Re: Conky Showoff thread

Post by I_can_see_the_light »

Image
Click image for full size

Nothing overly fancy, just some basic non-intrusive info

.conkyrc
Transparency in KDE enabled by putting the line

Code: Select all

feh --bg-scale "`grep 'wallpaper=' ~/.kde/share/config/plasma-desktop-appletsrc | tail --lines=1 | sed 's/wallpaper=//'`"
into your .conkyrc or startup script
edwardr

Re: Conky Showoff thread

Post by edwardr »

My conky now has two parts, the first one starts when I start up:

Image


And a second conky that starts after I start my music player (Guayadeque) to show song info:

Image

clicking on the Guayadeque program launcher on my panel actually launches a script that starts Guayadeque and then starts the second conky.
edwardr

Re: Conky Showoff thread

Post by edwardr »

Meskarune - Nice and clean, I like it.
Locked

Return to “Compiz, Conky, Docks & Widgets”