2

I've been messing around with Conky for a while now and I recently started dabbling in Lua scripting. One of the things that used to bug me about a "flat" conkyrc approach (as opposed to a combined conkyrc and lua script) was that you had to set the position for everything using trial and error.

Using lua and cairo I was hoping to avoid that: I get the screen resolution from xdpyinfo and make all my dimensions relative to the screen resolution. The problem with this approach is that I still need to adjust the Conky window position from within the conkyrc file and (as far as I know) it can't be done programmatically. So my question is, can I use the results from my lua script to set Conky configuration variables like gap_x and gap_y? Or is there maybe another way to set these variables programmatically?

0

Perhaps not the solution I had in mind, but a solution nonetheless: the Conky Lua API describes a conky_config function that returns "[a] string containing the path of the current Conky configuration file."

So my solution would be to open this file and edit it in place from within my lua script.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.