Update: Combining calcurse and conky

Wow, that was fast! I only wrote the bug report to the creator of calcurse two days ago and received a patched version yesterday already! That’s what I call support. I tried this new version and can absolutely confirm that the bug I reported is fixed. Thus, it’s time I update my conky adaption as well. Not much needs changing, but there’s one thing I didn’t consider about when creating the “workaround” version…

The “workaround” version of my script relies on the .conkyrc file to insert an empty line between the todo’s and the appointments. If you don’t need such a line, you can skip reading the rest of this blog entry. All others need to patch the script. First, edit your .conkyrc to call the script only once, but with the parameters for both the appointments and todo’s:

${execpi 300 calcurse -d14 -t | ~/.conky/calcurse_task_to_conky.pl}

Then, save the following patch as ~/.conky/new_version.patch:

< sub spacer
< {
<     if( ${ (\scalar keys %inited) } > 0 )
<     {
<         print "\n";
<     }
< }
<             spacer();
<             spacer();

Finally, apply the patch:

patch -R -i ~/.conky/new_version.patch ~/.conky/calcurse_task_to_conky.pl

That’s it! Now the appointments and todo’s always have a separating line between them.

Leave a Reply

You must be logged in to post a comment.