I'm trying to create a workaround for Conky's truncation of usernames with the top user
function. Using id -nu $uid
, I tried this:
${exec id -nu ${top uid \1}}
which leads to "bad substitution" errors. Thinking that it may be because the top function is sending a string instead of an integer, I tried creating a lua function:
function conky_uid_to_name(uid)
num = tonumber(conky_parse(uid))
name = conky_parse('${exec id -nu ${num}}')
return name
end
but this never works either as I can't get the parser to see my variable. How do I send a variable to the name
variable to be properly parsed by Conky? I'm sure there's an easier way of doing this, but I'm not finding many lua examples and their docs are severely lacking.