View previous topic :: View next topic |
Author |
Message |
VinzC Watchman
Joined: 17 Apr 2004 Posts: 5098 Location: Dark side of the mood
|
Posted: Wed Mar 27, 2013 1:49 pm Post subject: Dynamic graphs in conky |
|
|
Hi again.
I'd like to know if (and possibly how) I can have dynamic graphs in conky. For instance whenever I establish a VPN connection Gkrellm immediately shows the network graph as soon as device ppp0 is available. The graph should go when the link is closed. I'd like to achieve the same feature with conky. Is it possible?
Here's my current theme. It is based on Fedora's and I have customized it with an indication of which package is being compiled. I also added a second network graph for my Ethernet adapter. So next in my list are dynamically show my USB disks activity like in Gkrellm and my VPN connection, similar to what I have with eth0 and wlan0.
Thanks for any hint or suggestion. _________________ Gentoo addict: tomorrow I quit, I promise!... Just one more emerge...
1739! |
|
Back to top |
|
|
Anon-E-moose Watchman
Joined: 23 May 2008 Posts: 6098 Location: Dallas area
|
Posted: Wed Mar 27, 2013 2:17 pm Post subject: |
|
|
${if_existing /proc/net/route ppp0}<display whatever>${endif} _________________ PRIME x570-pro, 3700x, 6.1 zen kernel
gcc 13, profile 17.0 (custom bare multilib), openrc, wayland |
|
Back to top |
|
|
VinzC Watchman
Joined: 17 Apr 2004 Posts: 5098 Location: Dark side of the mood
|
Posted: Thu Mar 28, 2013 10:49 am Post subject: |
|
|
Anon-E-moose wrote: | ${if_existing /proc/net/route ppp0}<display whatever>${endif} |
Excellent! It even spans across multiple lines. I had to pay attention to a few details but it works like a charm. Thanks a lot! _________________ Gentoo addict: tomorrow I quit, I promise!... Just one more emerge...
1739! |
|
Back to top |
|
|
Anon-E-moose Watchman
Joined: 23 May 2008 Posts: 6098 Location: Dallas area
|
Posted: Thu Mar 28, 2013 10:53 am Post subject: |
|
|
I should have mentioned to not leave a space between the if closing curly bracket and the 1st command
and the same for the last command and $endif (it leaves a blank line otherwise)
ie
${if_existing /proc/net/route ppp0}1st command
...
last command${endif}
leaves no spaces
${if_existing /proc/net/route ppp0}
1st command
...
last command
${endif}
leaves a space at beginning and end _________________ PRIME x570-pro, 3700x, 6.1 zen kernel
gcc 13, profile 17.0 (custom bare multilib), openrc, wayland |
|
Back to top |
|
|
VinzC Watchman
Joined: 17 Apr 2004 Posts: 5098 Location: Dark side of the mood
|
Posted: Thu Mar 28, 2013 11:10 am Post subject: |
|
|
Indeed I noticed every character and space counts in the text block but that was no big deal. _________________ Gentoo addict: tomorrow I quit, I promise!... Just one more emerge...
1739! |
|
Back to top |
|
|
VinzC Watchman
Joined: 17 Apr 2004 Posts: 5098 Location: Dark side of the mood
|
Posted: Thu Mar 28, 2013 7:50 pm Post subject: |
|
|
I updated my old Conky theme. You can find it here with all dependencies. _________________ Gentoo addict: tomorrow I quit, I promise!... Just one more emerge...
1739! |
|
Back to top |
|
|
|