Fedora Linux Support Community & Resources Center
Old 6th July 2008, 02:16 PM
storskogen Offline
Registered User
Join Date: Sep 2006
Location: Sweden
Age: 39
Posts: 58
remove unwanted stuff with sed

Im trying to get conky to show my current cpu-speed

${execi 5 cat /proc/cpuinfo | grep 'model name' | sed -e 's/model name.*: //' | sed -e 's/@ //' | tail -n1} @ ${execi 5 cat /proc/cpuinfo | grep -w cpu\ MHz | sed -e 's/cpu.*MHz.*://' | sed -e 's/000//' | tail -n1}Mhz
but get i cant get rid of the last . when running at 800Mhz (showing 800.MHz), when running at 2Ghz it shows '2.000MHz'

Im not sure if thats understandable :$
Laptop: Fujitsu-Siemens Amilo Li1718 Fedora 8/WinXP/Fedora 10
Desktop: AMD Athlon 64 X2 Fedora 8/WinXP (only for games)
Mediaplayer: MacMini G4 OS-X Tiger (kitchen)
Server: Mini-ITX Epia ME6000 Fedora 10
Reply With Quote
Old 6th July 2008, 02:35 PM
MSK61 Offline
Registered User
Join Date: May 2008
Location: Giza, Egypt
Age: 34
Posts: 167
A little more clarification please. I don't understand exactly what your problem is.
Reply With Quote
Old 6th July 2008, 04:55 PM
archo Offline
Registered User
Join Date: May 2007
Posts: 15
Try changing the last
sed -e 's/000//'
 sed -e 's/\.000.*$//'
My laptop smolt profile
Reply With Quote

remove, sed, stuff, unwanted

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to remove unwanted kernels larryt Using Fedora 6 4th August 2007 07:04 PM
remove an unwanted rpm Jeff Sadowski Using Fedora 2 22nd March 2007 05:05 PM
how to remove unwanted driver first007boy Hardware & Laptops 6 14th January 2006 03:46 AM
How to disable or remove unwanted plug-in from firefox first007boy Using Fedora 2 18th October 2005 08:09 AM
how do i remove unwanted charaters at "script" command output? linuxzouk Using Fedora 1 15th May 2004 11:05 PM

Current GMT-time: 23:26 (Thursday, 17-08-2017)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat