Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[Solved] A conky shortcut problem
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
double_crane
Tux's lil' helper
Tux's lil' helper


Joined: 11 Dec 2011
Posts: 85
Location: JiangSu,China

PostPosted: Sat Sep 21, 2013 12:47 pm    Post subject: [Solved] A conky shortcut problem Reply with quote

Problem: conky doesn't show hard disk temperature ,when start conky by shortcut ;and show hdd temp when run conky in terminal command line.

I emerged conky with hddtemp use.
and I had chmod +s /usr/sbin/hddtemp

and in ~/.conkyrc:

Code:
${color #98c2c7}HDD: ${color #db7093}${alignr}${execi 1 hddtemp -q /dev/sda|cut -c 36-37}°C


when run
Code:
hddtemp -q /dev/sda|cut -c 36-37
in gnome-terminal , I can get the HDD temp.

and when I start conky in gnome-terminal , I can get HDD temp too.

but when I start conky by shortcut , I can not. Others in conky is all right ,CPU temp ,GPU temp,and other all right.

I use gconf-editor to set the shortcut , blind Ctrl+Alt+C to run /opt/bin/con_ky_shortcut:
Code:

conkyname=`ps -A |grep conky |awk '{print $4}'`

conkyid=`ps -A |grep conky |awk '{print $1}'`

if [ -z "$conkyname" ] ; then

        echo conky not running,start it
        conky

else
        echo conky already running
        echo conkyid:$conkyid
fi



when run /opt/bin/conky_short in gnome-terminal , HDD temp is seen in conky.

Only when I click the shortcut Ctrl+Alt+C , conky starts ,others all right ,but HDD temp is blank.

is this a bug ?
or how to solve?


Last edited by double_crane on Sat Sep 21, 2013 4:28 pm; edited 1 time in total
Back to top
View user's profile Send private message
Anon-E-moose
Advocate
Advocate


Joined: 23 May 2008
Posts: 2101
Location: Dallas area

PostPosted: Sat Sep 21, 2013 4:07 pm    Post subject: Reply with quote

try /usr/sbin/hddtemp and see if that won't work

or use the conky built in variable
Code:
${hddtemp /dev/sda}

_________________
Asus m5a99fx, FX 8320 - amd64-multilib, 3.9.1-zen, eudev
glibc-2.17, gcc-4.7.3-r1, xorg-server-1.15, lxde, nouveau, oss4
Back to top
View user's profile Send private message
double_crane
Tux's lil' helper
Tux's lil' helper


Joined: 11 Dec 2011
Posts: 85
Location: JiangSu,China

PostPosted: Sat Sep 21, 2013 4:28 pm    Post subject: Reply with quote

Anon-E-moose wrote:
try /usr/sbin/hddtemp and see if that won't work

or use the conky built in variable
Code:
${hddtemp /dev/sda}


Thank you
/usr/sbin/hddtemp is OK,
but /usr/sbin is in myuser and root's PATH..

and {hddtemp /dev/sda} don't work ,it's not conky's grammer.

So easy a question......
Thank you again.
Back to top
View user's profile Send private message
Mistwolf
Tux's lil' helper
Tux's lil' helper


Joined: 07 Mar 2007
Posts: 106
Location: Edmonton, AB

PostPosted: Sat Sep 21, 2013 4:38 pm    Post subject: Reply with quote

{hddtemp /dev/sdx} is valid only if conky was compiled with the hddtemp use flag enabled.

Hope this helps.[/code]
Back to top
View user's profile Send private message
Anon-E-moose
Advocate
Advocate


Joined: 23 May 2008
Posts: 2101
Location: Dallas area

PostPosted: Sat Sep 21, 2013 4:50 pm    Post subject: Reply with quote

It's ${hddtemp /dev/sda} not {hddtemp /dev/sda}
and yes it works, that's how I have mine set up.

http://conky.sourceforge.net/variables.html


As far as hddtemp's path, it may be in your path as user, but might not be when run from a shortcut.
When in doubt, I always use the full path (makes it a smidgen faster than following $PATH lookup)

Anyway glad it's solved.
_________________
Asus m5a99fx, FX 8320 - amd64-multilib, 3.9.1-zen, eudev
glibc-2.17, gcc-4.7.3-r1, xorg-server-1.15, lxde, nouveau, oss4
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum