Auto Conky for Mint

Forum rules
Before you post please read how to get help

Auto Conky for Mint

Postby RedWagon on Wed Apr 14, 2010 11:50 am

I was poking around the community site last night and saw Mint Conky at the top of the list of all the ideas. This is something I can do, so I decided to start messing with an auto-configure script for conky. There are a few things I'd like some suggestions on:
Figuring out how many CPU cores a computer has (even hyperthreaded ones)
Finding all mounted drives. Mount gives too much info, I was thinking of getting the devices from fdisk -l and then using that to filter out the list in mount but I haven't really messed around with it yet.

I already got the networking stuff figured out:
Code: Select all
ifconfig | grep -v Loopback | grep -v 00-00-00-00 | grep 'Link encap' | awk '{print $1}'

will show me what network cards are installed and
Code: Select all
iwconfig 2> /dev/null | grep IEEE | awk '{print $1}'

will let me know which cards are wireless.

Once I can properly detect everything writing the program should be fairly easy. I plan on having a couple themes people can choose from and maybe add some switches to allow users to manually turn chunks on or off.
User avatar
RedWagon
Level 5
Level 5
 
Posts: 644
Joined: Tue May 26, 2009 6:41 pm

Linux Mint is funded by ads and donations.
 

Re: Auto Conky for Mint

Postby Aging Technogeek on Sun Apr 18, 2010 3:16 pm

This will be a great addition to Mint 9 if you can finish it. Many more people would use Conky if it were easier to configure. I've been in Linux for well over a year and only very recently did I feel competent enough to tackle a full Conky install.

Keep up the good work and let us know if you need testers of coding help (I can't code but I'm a whale of a good tester)

On the questions you posted, have you checked into hardinfo (System Profiler) to get the information on CPU cores? Or maybe System Monitor?
Image

Registered Linux User 483387
User avatar
Aging Technogeek
Level 13
Level 13
 
Posts: 4604
Joined: Sun Jan 11, 2009 9:54 am
Location: Right about here

Re: Auto Conky for Mint

Postby Kaye on Mon Apr 19, 2010 8:51 am

In addition to an autoscript, we might want to consider a GUI that will generate custom conky scripts because of the extra flexibility that would provide. Perhaps something similar to https://sourceforge.net/projects/conkygui/.

Perhaps a little less technical than what's showed in that picture. Just an idea.
"In somnis veritas"
Antivirus or defragging?
Image
User avatar
Kaye
Level 5
Level 5
 
Posts: 942
Joined: Fri Feb 06, 2009 5:05 pm
Location: Boston College

Re: Auto Conky for Mint

Postby RedWagon on Mon Apr 19, 2010 1:01 pm

Try running these and see if they get the right results:

Number of processor cores:
Code: Select all
grep processor /proc/cpuinfo | wc -l

Mounted hard drives:
Code: Select all
mount -l | grep /dev/[m,h,s]d | awk '{print $3}'


I'm thinking I'll need to so something to filter out cdroms.
User avatar
RedWagon
Level 5
Level 5
 
Posts: 644
Joined: Tue May 26, 2009 6:41 pm

Re: Auto Conky for Mint

Postby Aging Technogeek on Mon Apr 19, 2010 2:55 pm

RedWagon,

Tried both commands.

Command 1.
Code: Select all
grep processor /proc/cpuinfo | wc -l

On my desktop running an Intel Core 2 Quad, command returns - 4
On Laptop running Core 2 Duo, command returns - 2
On netbook running hyperthreading Intel Atom N270, command returns - 2

Command 2.
Code: Select all
mount -l | grep /dev/[m,h,s]d | awk '{print $3}'

On desktop, command returns - /,/home, /media/Data. This is correct for the system.
On laptop, command returns - /, /home. Correct
On netbook, command returns - /, /home. Correct.

Desktop running Mint 8 Main x64
Laptop running Mint 8 Main x32
Netbook running Mint 8 XFCE
Image

Registered Linux User 483387
User avatar
Aging Technogeek
Level 13
Level 13
 
Posts: 4604
Joined: Sun Jan 11, 2009 9:54 am
Location: Right about here

Re: Auto Conky for Mint

Postby vincent on Tue Apr 20, 2010 12:47 am

Code: Select all
vincent@Vincent-laptop ~ $ grep processor /proc/cpuinfo | wc -l
2
vincent@Vincent-laptop ~ $ mount -l | grep /dev/[m,h,s]d | awk '{print $3}'
/
/boot
/home


The info provided by those commands are all correct. (LG R580 w/ Intel Core 2 Duo T6500 2.1 GHz; my Linux partitions include /, /boot, /home, and /swap.)
Debian Testing x64/LM9 Main x64/Windows 7 x64 - LG R580 laptop w/ Intel Core 2 Duo T6500 2.1 GHz, 4 GB DDR2 RAM, Nvidia Geforce G 105M, Ralink rt2860 802.11n, 300 GB WD HD 5400 rpm
vincent
Level 8
Level 8
 
Posts: 2220
Joined: Tue Feb 09, 2010 4:10 am

Re: Auto Conky for Mint

Postby RedWagon on Tue Apr 20, 2010 2:54 am

eh, you don't want boot showing up in conky. I'll grep that out of there.
User avatar
RedWagon
Level 5
Level 5
 
Posts: 644
Joined: Tue May 26, 2009 6:41 pm

Linux Mint is funded by ads and donations.
 

Return to Compiz, Conky, Docks, & Widgets

Who is online

Users browsing this forum: No registered users and 2 guests