Conky Assistance

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.
Locked
SignatureSeriesOwner

Conky Assistance

Post by SignatureSeriesOwner »

Hi everyone,

I'm new to the Linux game, and installed Linux Mint 9 on my Vista laptop this AM (Wow, what an improvement) but I miss my sidebar gadgets.

I've seen Conky used to add sidebar gadgets, weather, etc. on the desktop, but have no idea how to do so.

Is it possible someone could help me with this? All I'd want is a CPU/RAM usage/load monitor, Network connection monitor (incoming/outgoing data and so on) weather, and maybe something else useful you guys can think of? Keep in mind I have NO idea how to edit, tweak, or write code, or the process to use/edit Conky to tweak my background. A step by step would be fantastic, if I;'m not asking too much. I read a tutorial on the Ubuntu forum, and am still at a loss.


Any assistance you all could give would be MUCH appreciated. I don't know if messing up the code (if I was to try it by myself) would mess up the desktop or not. Like I said, totally new to the game, although I'm loving it so far. :D
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
colyn

Re: Conky Assistance

Post by colyn »

Check out this thread to get ideas on setting up a conky. You will also need conky installed

Code: Select all

sudo apt-get install conky-all
at the terminal. Once you get conky installed and a .conkyrc file saved to your home folder you can start it by typing

Code: Select all

conky
at the terminal.

http://forums.linuxmint.com/viewtopic.php?f=60&t=30209

As for getting weather information you will need to write script file(s)
SignatureSeriesOwner

Re: Conky Assistance

Post by SignatureSeriesOwner »

How does one write a script file? It can't be as simple as "Weather for 23883, forecast, current temperature, live radar" or something. I've never done any program writing or anything. I wouldn't even know how to properly type it.
vrkalak

Re: Conky Assistance

Post by vrkalak »

You might, also, read through the posts on this thread.
Conky Show-ff thread >> http://forums.linuxmint.com/viewtopic.php?f=60&t=30209
It's where I learned about Conky and setting up a ~/.conky file and I borrowed scripts from there.

Conky is a great light-weight System Monitor.

Main Conky site >> http://conky.sourceforge.net/
Conky Wiki >> http://wiki.conky.be/index.php?title=Conky_Wiki
Conky Hard-core >> http://conkyhardcore.com/
Conky Pit-stop >> http://conky-pitstop.wikidot.com/
Official Conky Blog >> http://blog.conky.be/2010/05/12/omg-con ... um=twitter

And all the main/major/popular Linux Distros, each has a good Conky and Conky-Help sections in their respective Forums.
Checkout: the Ubuntu, Crunchbang, Mint, Fedora, Arch Forums.
dawgdoc

Re: Conky Assistance

Post by dawgdoc »

This post by Cupragtr has a weather script available to copy http://forums.linuxmint.com/viewtopic.p ... 40#p104554
he uses 2 conky setups on the same desktop, it also has scripts to show birthdays, anniversaries and gmail status.

THIS Ubuntu topic is comparable the the Mint thread for Conky Showoff but has many more entries.
SignatureSeriesOwner

Re: Conky Assistance

Post by SignatureSeriesOwner »

Well, I tried typing the sudo, get conky command, it worked, but nothing was installed as I did it last night, then I typed in "conky" at the terminal, and the terminal just keeps scrolling down with "no such file or directory" "file not found" etc. etc. So I must have done something wrong. I pasted a script in the "edit conky" window, saved it, and it did nothing.



edit:


AHA! it just took it a little bit to show up. The only issue is, a few things are overlapping. Is there a way to correct that?



Thank you for all the help so far, everyone. :)
dawgdoc

Re: Conky Assistance

Post by dawgdoc »

In another thread vrkalak posted a LINK to a Make Tech Easier article regarding installing and using ConkyWizard, a GUI application to configure conky. This may be the simplest way for you to adjust how conky displays.

Otherwise, it is a lot of trial and error with spacing and offset tags.
SignatureSeriesOwner

Re: Conky Assistance

Post by SignatureSeriesOwner »

Ok, so this is the script I am working with.




##############################################
# Settings
##############################################
background yes
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 yes
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}

${color5}${alignc 19}${font Trebuchet MS:size=22}${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=22}Linux Mint 9${font}
${color0}System:$alignr$sysname $machine
Kernel:$alignr$kernel
Host:$alignr$nodename

CPU Freq: ${alignr}${freq_g} GHz AMD Athlon 64 X2
${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}NETWORK ${hr 2}${color}${font}

${color0}IP Address: $alignr ${addr eth0} (IP ADDRESS HERE?)
${color0}Down ${downspeed eth0} k/s ${alignr}Up ${upspeed eth0} k/s
${color FFFF99}${downspeedgraph eth0 25,107} ${alignr}${upspeedgraph eth0 25,107}
${color2}Total ${totaldown eth0} ${alignr}Total ${totalup eth0}

${color4}${font Sans:bold:size=8}WEATHER ${hr 2}${font}${color0}

${execi 1800 /home/william/scripts/weather.sh USVA23883} ZIP CODE HERE?
${color4}${font Sans:bold:size=8}CALENDAR ${hr 2}${font}${color0}

${color0}${font Monospace:size=9}${execpi 60 DJS=`date +%_d`; cal | sed '1d' | sed '/./!d' | sed 's/$/ /' | fold -w 21 | sed -n '/^.\{21\}/p' | sed 's/^/${alignc} /' | sed /" $DJS "/s/" $DJS "/" "'${color FFCC00}'"$DJS"'${color0}'" "/}${font}
${color4}${hr 1}


Everything works/looks fantastic, except for the weather, and the network portion. Now, I tried adding my ZIP code, to no avail, and I don't know what I need to edit in the network section for it to detect / display my wireless connection info.

Any ideas so far? I've been tweaking a few things, and it;'s really a good deal easier than I though. But when it comes to having to enter all new info/script, I'm still not sure of what to type for it to accept it/function.
SignatureSeriesOwner

Re: Conky Assistance

Post by SignatureSeriesOwner »

dawgdoc wrote:In another thread vrkalak posted a LINK to a Make Tech Easier article regarding installing and using ConkyWizard, a GUI application to configure conky. This may be the simplest way for you to adjust how conky displays.

Otherwise, it is a lot of trial and error with spacing and offset tags.
Ah, sorry,I didn't see your post there before I posted mine. I just downloaded it, and while it seems fairly easy to deal with, I think I'll put it to use on the other computer, as I haven't gotten to fiddling around with it (conky) yet. I've already got the one on this one downpat, save for the weather and network (see post above)


Thanks for the link! That will make working on it in the future far easier.
dawgdoc

Re: Conky Assistance

Post by dawgdoc »

SignatureSeriesOwner wrote:${color4}${font Sans:bold:size=8}NETWORK ${hr 2}${color}${font}

${color0}IP Address: $alignr ${addr eth0} (IP ADDRESS HERE?)
${color0}Down ${downspeed eth0} k/s ${alignr}Up ${upspeed eth0} k/s
${color FFFF99}${downspeedgraph eth0 25,107} ${alignr}${upspeedgraph eth0 25,107}
${color2}Total ${totaldown eth0} ${alignr}Total ${totalup eth0}
Try changing each occurance of eth0 to either eth1 or wlan0 eth0 typically refers to a wired ethernet connection, wireless will probably be either eth1 or wlan0. if you enter iwconfig in a terminal you should be able to tell which to use based on the output.
SignatureSeriesOwner

Re: Conky Assistance

Post by SignatureSeriesOwner »

dawgdoc wrote:
SignatureSeriesOwner wrote:${color4}${font Sans:bold:size=8}NETWORK ${hr 2}${color}${font}

${color0}IP Address: $alignr ${addr eth0} (IP ADDRESS HERE?)
${color0}Down ${downspeed eth0} k/s ${alignr}Up ${upspeed eth0} k/s
${color FFFF99}${downspeedgraph eth0 25,107} ${alignr}${upspeedgraph eth0 25,107}
${color2}Total ${totaldown eth0} ${alignr}Total ${totalup eth0}
Try changing each occurance of eth0 to either eth1 or wlan0 eth0 typically refers to a wired ethernet connection, wireless will probably be either eth1 or wlan0. if you enter iwconfig in a terminal you should be able to tell which to use based on the output.

Bingo. Switching it all to eth1 fixed it right up. Thanks!
dawgdoc

Re: Conky Assistance

Post by dawgdoc »

Glad to have been of assistance.
LowTech

Re: Conky Assistance

Post by LowTech »

I know that this is old, but . . .
what networking code would you use if you were using a tethered connection?

*Found it, for me it's "klink0"*
Locked

Return to “Compiz, Conky, Docks & Widgets”