خرید بک لینک

Greetings, I'm attempting to use Conky to overlay information about my hardware. I've managed to modify the default Conky config to my liking, however there's one line that's giving me an error ( bad substitution ). The command works perfectly in terminal but not with Conky.

This is the line of code. I'm attempting to make a bar which is filled based on GPU load. The error is produced when I attempt to pipe the 'grep' output to 'awk' which is supposed to remove the percent sign from the string ( execbar does not seem to like percent signs ).

Code:

${execbar ${exec aticonfig --adapter=0 --od-getclocks | grep -i -o [0-9]% | awk 'sub(/%/, "")' } }
Output when using commands in terminal:

Code:

runedog48@ThomasTheTrain /etc/conky $ aticonfig --adapter=0 --od-getclocks | grep -i -o [0-9]%
0%
runedog48@ThomasTheTrain /etc/conky $ aticonfig --adapter=0 --od-getclocks | grep -i -o [0-9]% | awk 'sub(/%/, "")' 
0
Side note: I've only started using Linux as my daily driver about 2 weeks ago ( used Windows my whole life ), but I've been programming for a while. I'm still getting used to the switch and there's a lot I don't know yet.

Any help would be greatly appreciated.

برچسب: نویسنده: استخدام کار تاريخ: شنبه 5 تير 1395 ساعت: 4:35

صفحه بندی