How to get conky work on LXDE?
conky is a cool tool to see your system resource utilization. I felt it is better than gkrellm But when I switched to LXDE (my laptop has only 1.5 GB and can't expand anymore) I could not get it to work. After much googling, I figured out that it is a problem with pcmanfm managing wallpapers and the solution is to use another image viewer -- feh. I use F17 and feh is available in the fedora repositorySo, the procedure was simple. Just issue,
$ sudo yum install feh
Going through the man page of feh exposed some interesting details. One is that -- quoting the man page
feh can also be used as a background setter. Unless you pass the --no-fehbg option, it will store the command line necessary to set the background in ~/.fehbg, so to have your background restored everytime you start X, you can add "eval $(cat ~/.fehbg)" to your X startup script (like ~/.xinitrc).
Yo.. easy! So I need to add desktop file to autostart directory that will kick off this command.
How to create a .desktop file?
LXDE comes with a tool called lxshortcut. Run it$ lxshortcut -i shcut-to-script.desktop
So, you should get this dialog box
Now, fill the input fields and click OK. copy the .desktop file to ~/.config/autostart/ . LXDE will execute these shortcuts while starting up.
But did it solve my problem?
Sadly, No. I could not get conky even after I tried the above steps. For two seconds after I login, I see conky, then it disappears. After a while of wading through google search results, I found out that I have to make pcmanfm not manage my desktop
So, I modified my script to do that as well by this command
$ cat ~/.lxde-conky.sh
pcmanfm --desktop-off
conky & # Note this, conky must be pushed to background
sleep 1
eval $(cat ~/.fehbg )
And you can see the result here.

Edit:
Since you make the pcmanfm not manage desktop anymore (note the --desktop-off in the above file), you _should_ have some application (like feh above) to show a wallpaper or no wallpaper -- that is, to refresh the desktop. Otherwise, you will end up with a desktop not refreshed by anyone -- Dragging/closing the windows will start leaving a trail of window movements...

No comments:
Post a Comment