You are not logged in.

#1 2018-06-12 23:39:18

verndog
Member
Registered: 2018-05-22
Posts: 27

[SOLVED] conkyrc trouble

I know this forum has conky experts. What I don't know is where to put my conky questions.
I searched but found no conky subfloor.

Yesterday, I wanted to rid my conky of the ticking seconds. So after much hoopla, I found the two places I needed to edit.

This for "BL-Right-lua.conkrc":
Line 99 "${time %I:%M %p}",took care of the top yellow time seconds.
Line 104 "Uptime:${alignr}${uptime}", was changed to Uptime:${alignr}${uptime_short}. That worked. Now it doesn't.

EDIT:As I suspected. Once it reaches the hour mark the seconds stop! A fly in the ointment? "uptime_short" seems to only work after the hour. I'll read up on that Object.

EDIT2: I found same discussion (answer?) here

EDIT3: This is whats suggested:Uptime:${alignr}${format_time $uptime_short "\hh\mm"}, but that doesn't work

Last edited by verndog (2018-06-14 03:01:12)

Offline

#2 2018-06-13 03:50:45

ohnonot
...again
Registered: 2015-09-29
Posts: 2,653
Website

Re: [SOLVED] conkyrc trouble

i'm not sure i understand what "doesn't work".
it's perfectly possible to have both time and uptime without seconds.

please do some troubleshooting:
run the conky in question from a command line and see if you get relevant error messages.

if that doesn't help, please post the complete conky config file here. please use code tags for code.

PS: no, there's no dedicated subsection for conky, but ~3 sticky threads.

Offline

#3 2018-06-13 15:33:17

PackRat
Member
Registered: 2015-10-02
Posts: 724

Re: [SOLVED] conkyrc trouble

verndog wrote:

Line 104 "Uptime:${alignr}${uptime}", was changed to Uptime:${alignr}${uptime_short}. That worked. Now it doesn't.

EDIT:As I suspected. Once it reaches the hour mark the seconds stop! A fly in the ointment? "uptime_short" seems to only work after the hour. I'll read up on that Object.

EDIT2: I found same discussion (answer?) here

EDIT3: This is whats suggested:Uptime:${alignr}${format_time $uptime_short "\hh\mm"}, but that doesn't work

That just started happening with conky 1.10 (and whatever BL is using, still 1.9?). There's no error message if conky is started from a terminal, so it's a fly in the ointment. The uptime is still short in the sense that only two values are given; it's like the code conky uses to parse uptime_short is a bit depricated.

Try this in a terminal:

uptime | awk -F, '{sub(".*up ",x,$1);print $1}'

I use that to get uptime in polybar, if you prefer that output, you can run it in conky.


It is difficult to get a man to understand something when his salary depends upon his not understanding it.
                                                                                                                                       Upton Sinclair

Offline

#4 2018-06-13 17:06:43

hhh
TESTING!!!!!!!
Registered: 2015-09-17
Posts: 5,038
Website

Re: [SOLVED] conkyrc trouble

ohnonot wrote:

PS: no, there's no dedicated subsection for conky, but ~3 sticky threads.

Heads up, there's now just one conky sticky in the 'Scripts, etc...' forum, it's the only sticky there. The other threads exist, but we had a dozen stickies which was nuts. I unstickied everything else to see which threads will rise to the top via activity.

This thread is fine here, this is absolutely a basic help question and not conky minutia.

Online

#5 2018-06-13 22:01:14

verndog
Member
Registered: 2018-05-22
Posts: 27

Re: [SOLVED] conkyrc trouble

PackRat wrote:

...
That just started happening with conky 1.10 (and whatever BL is using, still 1.9?). There's no error message if conky is started from a terminal, so it's a fly in the ointment. The uptime is still short in the sense that only two values are given; it's like the code conky uses to parse uptime_short is a bit depricated.

Try this in a terminal:

uptime | awk -F, '{sub(".*up ",x,$1);print $1}'

I use that to get uptime in polybar, if you prefer that output, you can run it in conky.

That awk script works. Thanks.

If you follow the link I showed above, there's another link that has some very long scripts that I wasn't about to use.

Also I don't know how true this statement is "Conky ver. 1.10.1 will show uptime_short without seconds", again from the above link.

Will BL upgrade Conky versions or is this up to the user?

Offline

#6 2018-06-13 22:10:40

hhh
TESTING!!!!!!!
Registered: 2015-09-17
Posts: 5,038
Website

Re: [SOLVED] conkyrc trouble

We stick to Debian stable whever possible, but build new packages of what we consider "important" packages in our backports repos. conky is a basic element of our desktop, we'll surely provide a backport when the time comes.

We currently use the conky-all version in stable, 1.10.6. The version in testing and sid is 1.10.8...

https://packages.debian.org/search?suit … =conky-all

Online

#7 2018-06-13 22:18:05

hhh
TESTING!!!!!!!
Registered: 2015-09-17
Posts: 5,038
Website

Re: [SOLVED] conkyrc trouble

Uptime:${alignr}${uptime_short}

I just used this and the seconds were gone immediately using an edited default conky (not one of the lua scripts).

Are you saying the seconds will return after the hour is up?

-edit- Uptime is now 5h 7m. Seconds are not displayed. Maybe this will change for the first hour after a reboot, not a big deal.

Online

#8 2018-06-13 22:34:48

verndog
Member
Registered: 2018-05-22
Posts: 27

Re: [SOLVED] conkyrc trouble

hhh wrote:
Uptime:${alignr}${uptime_short}

I just used this and the seconds were gone immediately using an edited default conky (not one of the lua scripts).

Are you saying the seconds will return after the hour is up?

No the other way round. The seconds disappear AFTER the hour mark.

Using @PacRat's script I needed to use "exec" for it to run correctly:

Uptime: ${alignr}${exec uptime|awk -F, '{sub(".*up ",x,$1);print $1}'}

Offline

#9 2018-06-13 23:50:50

PackRat
Member
Registered: 2015-10-02
Posts: 724

Re: [SOLVED] conkyrc trouble

instead of this:

Uptime: ${alignr}${exec uptime|awk -F, '{sub(".*up ",x,$1);print $1}'}

try:

Uptime: ${alignr}${execpi 60 uptime|awk -F, '{sub(".*up ",x,$1);print $1}'}

that should work and uptate your Uptime every minute instead of the conky refresh time; change the "60" to whatever interval you want.

Also I don't know how true this statement is "Conky ver. 1.10.1 will show uptime_short without seconds", again

We currently use the conky-all version in stable, 1.10.6. The version in testing and sid is 1.10.8

This just started happening on my Void system - 1.10.7 - the other day; and my BL-Sid system shows the seconds as well. So some random bug, I guess.


It is difficult to get a man to understand something when his salary depends upon his not understanding it.
                                                                                                                                       Upton Sinclair

Offline

#10 2018-06-14 23:34:12

verndog
Member
Registered: 2018-05-22
Posts: 27

Re: [SOLVED] conkyrc trouble

Thanks for the Updated Uptime.

Offline

Board footer

Powered by FluxBB