January 19, 2009

Enigma ported to Linux

Inspired by the wonderful Enigma desktop by Kaelri, featured at Lifehacker, I decided to port at least some of the beautiful design to my Linux desktop.

The result is this:

Compared to the original theme:

My desktop features

  • Simple calendar — I even considered adding google calendar events using gcalcli, but the desktop was way too crowded
  • RSS news
  • Remember The Milk tasks
  • Weather Forecast
  • and system stats

Almost everything you see is drawn on desktop using conky. There are however, few major drawbacks:

  • With conky you get either full transparency, or no transparency at all. It's all or nothing
  • Conky cannot draw pictures.

So how did I get the transparent sidebars and icons? Gotcha! They are part of the desktop background.

I also decided to omit the analog clock — this is certainly doable with gdesklets or screenlets, but I almost fainted when I saw the dependencies. My desktop stays lightweight, no matter what. I tried the lightweight adesklets but the result was disappointing.

To recreate this desktop you need:

  • "Patched" background — I provide a GIMP layered image, you just need to replace the background layer for the image of your choice
  • Conky and conky configuration files
  • Weather fonts — fonts displaying weather conditions (included)
  • RTM command line tool for the RTM task list
  • I am using tint2 as the panel, but any transparent panel (such as gnome-panel) should do

Installing the RTM command line tool might be tricky, as the author notes, you need to install RTMAgent perl module first:

This package is split in two components:
  • RTMAgent.pm: a Perl module that implements the low-level API. It provides a UserAgent object which lets you call all of RTM's API methods as normal Perl methods. You will need to install it from CPAN: cpan install WebService::RTMAgent
  • rtm: a Perl script that uses RTMAgent to implement a command line interface. Just put it in your path.

It seems that there are two flavors of the cpan installation scripts, mine required the following syntax: cpan -fi WebService::RTMAgent, where -fi stands for force install, as one of the dependencies failed its unit tests. Your cpan scripts syntax might vary, check the corresponding manual first.

After installing the RTMAgent, run rtm --authorise, follow the generated link and allow RTM API access. This should be done only once, before the first run.

Don't forget to change your username and password in scripts/gmail.py and set your location code in scripts/conkyForecast.template. See the instruction for the weather forecast config.

That should be all. Both wallpaper and conky configs are designed for 1280x800 resolution, you'll probably have to move things a bit for different resolutions. Unpack the attached archive to ~ (archive contains hidden files, you have been warned), set the background, set up rtm, gmail and weather forecast and run ~/scripts/start_conky.

DOWNLOAD the background and scripts.

Credits:

I am aware, that the desktop still has some rough edges, but I am posting this in the spirit of

Release early, release often.


54 comments:

Anonymous said...

Just like to say thanks, appreciated! Got here via lifehacker so you'll prob have quite a few downloads :)

Anonymous said...

If you use google gadgets/screenlets partly instead of conky, you can get true transparency and a sidebar too.

Just a thought :)

-Pritam

Anonymous said...

If you use google gadgets/screenlets partly instead of conky, you can get true transparency and a sidebar too.

Just a thought :)

-Pritam

Unknown said...

For the center clock you coul use cairo-clock.

Unknown said...

If you want a lightweight clock for a really lightweight desktop, I recommend xonclock, it's dependencies are none beyond xlibs and libpng and libjpeg, and consumes around 2Mb of memory, and differently form cairo-clock it doesn't need a composite manager.

Anonymous said...

WOW, the great linux people with all their glossy high end visual effects are copying xp desktops an OS you linux guys so much hate cuz it's 9 years old and it still kicks your linux ass... LOL

Good luck with it btw it's time to grow up from the wobbly windows and drawing with fire effects :)

Aspanu said...

dtbsz, sadly, your comment couldn't be more wrong. But if you insist that windows rules and linux is just a copycat OS based off the much older Unix, so be it. Its great that one would embrace ignorance, the less people who use linux, the less exploitation to viruses and malware we shall receive.

Tomáš, Thank you for your work, I think it looks great! I'm only having a slight problem with CPAN/RTM right now, it appears to be broken, I have only seen one other person with the same problem over @ Ubuntu's forums, but no solutions as of yet.

Anonymous said...

could you please provide a link, or upload the background somewhere? if i extract it from the zip, it has those icons and stuff. would be really great!

thanks, and nice work!

Tomáš Kramár said...

@Anonymous: The background is part of the original Enigma package, you can get it at ~kaelri's deviantart page.

@Aspanu: Can you describe your problem? Maybe I could help.

@evandrofisico: xonclock looks great, I will definitely give it a try, thanks!

Aspanu said...

CPAN fails with the webservice::RTMAgent command, I tried several alternatives/Variations, I can't get RTMAgent to work I'll have to compile it from source, if I get it, and I'll let you know.

I'm using UbuntuStudio, btw. I have noticed variations in some code being broken between different versions of ubuntu as well debian, so this could be an isolted incident with my particular version CPAN.

Tomáš Kramár said...

@Aspanu: I am not sure if compiling it from source is a good idea. Installing it from cpan triggered a full tree of dependencies, which the script resolved automatically. Doing this manually would be a tedious task.

Did you try the "official method"?

cpan install WebService::RTMAgent

It didn't work for me, but at least the script suggested a correct syntax.

Carl said...

"Just put it in your path"

Sorry to be a noob, but what does that mean exactly in regards to rtm

Anonymous said...

Awesome! Great job! But...why did you use zip? This is linux, use tar.

Aspanu said...

The syntax bad, try

CPAN webservice::RTMAgent or

CPAN -fi webservice::RTMAgent

Tomáš Kramár said...

@Carl: It means you should place it somewhere, where your environment variable $PATH points (try echo $PATH), etc. /usr/bin

This is however not necessary, as the rtm script is already included in the archive and placed in the scripts/ directory. Just copy the directory to your home directory and it should be fine.

Unknown said...

Good work, i install this later.
Thanks!

kumorigoe said...

I'm not really sire what to do at this point.

I've downloaded the archive and extracted it to my home directory. I've installed the Perl stuff (I think). However, RTM comes back as an unknown command.

Tomáš Kramár said...

@kumorigoe: It is because you do not have it on your PATH. If you want to run the rtm command outside my conky scripts, copy it from ~/scripts to /usr/bin.

Again, this is not necessary for the enigma desktop, as I expect it to be in the ~/scripts, not on PATH.

kumorigoe said...

And ~ is the home directory?

Tomáš Kramár said...

Yes, ~ is your home directory.

Anonymous said...

Hi,

I have just installed it and everything works well. It looks very good. I am having one small issue, though. If I click on anything on the desktop, all of the information conky provides disappears. A ps aux indicates that it is still running in the background, however, they are no longer visible. I was wondering if anyone else was having the same issue, and what was done to fix it. I am running Debian unstable on a Dell Laptop (d810), radeon x600 with proprietary driver. Thanks again, J.

kumorigoe said...

Okay, I'm still a little lost.

I've downloaded the archive, placed it in my home directory, ran the terminal commands, and set the background for my desktop after resizing it to 1024x768.

I don't know how to "run" the scripts. I have the blank desktop with a mail icon, but nothing else.

Tomáš Kramár said...

@Anonymous: Did you modify conky configuration files? This seems like conky's own_window_type is not set to desktop. If you did not touch the configuration however, it seems like a bug. In that case, I recommend asking on conky mailing list or irc channel.

@kumorigoe: Assuming you have copied all the files from the archive (even the hidden directories .conky and .font), open terminal and type

~/scripts/start_conky

If you want to run this script at each startup, you need some extra work. This is DE dependent, if you are running gnome, try gnome session manager (somewhere in the menus). I am running openbox, so I'm not of much help here.

ifrit said...

Sorry, I'm a noob. Could anybody do a step by step tutorial?

Thnx!

Anonymous said...

Thanks for the quick reply...I figured it out. I had not modified the config files, but I saw your mention of special setting for nautilus. I killed nautilus and restarted conky, and all is good now. Thanks again...J.

kumorigoe said...

Okay, I think we're getting closer. I ran the command after extracting all the files to my home directory, and it comes back with:

robert@robert-laptop:~$ sudo ~/scripts/start_conky
/home/robert/scripts/start_conky: 3: conky: not found
/home/robert/scripts/start_conky: 4: conky: not found
/home/robert/scripts/start_conky: 5: conky: not found
/home/robert/scripts/start_conky: 6: conky: not found
/home/robert/scripts/start_conky: 7: conky: not found
/home/robert/scripts/start_conky: 8: conky: not found

Tomáš Kramár said...

@ifrit: Read the post, all you need to do is written there.

@kumorigoe: You need to have conky installed:

sudo aptitude install conky

..if you are running Ubuntu.

Also, there is no need to run the start_conky script as root, so don't run it with sudo.

kumorigoe said...

Tomas, thank you for all your patience.

Okay, I installed conky, and ran the comment to start it. This gave me the system monitor, but in it's own little window, rather than integrated into the desktop as the screenshot shows.

Tomáš Kramár said...

@kumorigoe: Make sure you have

own_window_type desktop

in your conky configuration file. If you do, you might have the same problem as the anonymous commenter above you. I think it might have something to do with the fact, that nautilus is drawing icons on desktop. I am not sure how he resolved this issue.

You might want to turn this behavior off in gconf (if you can live with no icons).

kumorigoe said...

Alright, now the desktop has brown bars top and bottom, and when I run the script, it opens five system monitor windows and nothing else.

Tomáš Kramár said...

Are you running my scripts, or your custom? The ~/scripts/start_conky should embed 6 conky windows to desktop.

I noticed that your resolution is 1024x768, so you might want to modify window positions.

Try this:

conky -c ~/.conky/conky_cal

This should run the calendar in the upper left corner. If the calendar does not appear, try to modify its position in config, kill conky, and start it again using the command above.

Repeat for each conky config, until you are satisfied.

Jacen said...

I really like the look and functionality of this desktop. ^_^ I've got almost everything running except for Remember the Milk. When I try to do rtm --authorise, I get this error message:

Can't locate Date/Manip.pm in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.10.0 /usr/local/share/perl/5.10.0 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.10 /usr/share/perl/5.10 /usr/local/lib/site_perl .) at /home/jacen/scripts/rtm line 58.

I'm running Ubuntu 8.10. RTM isn't really necessary for me but I would like to have it up. Thanks in advance.

Tomáš Kramár said...

Did you install RTMAgent and its dependencies?

Jacen said...

I did. At least, I thought I did. It told me I had to run it as root to do so, and that's what I did.

Tomáš Kramár said...

Try installing Date::Manip module from cpan. That should do it.

kumorigoe said...

Okay, I'm making more progress.

I think i have gotten the weather config correct with my license and key, and I can get the system window to display. However, I'm still getting brown bars at the top and bottom of my screen, and the weather information is bigger than the desktop, outside the right area where it should be.

Tomáš Kramár said...

I am not sure what are those brown bars, as I already said, try running conky windows one at a time and see, which of them are problematic.

Actually, I found the issue with weather conky now -- it only happens with a specific weather icon, so I initially missed it.

I will modify conky script and post an update.

kumorigoe said...

Okay, I found the problem with the bars. I hadn't properly resized the image.

r said...

I'm having trouble getting weather and system stats displaying. I had to fiddle with rtm (basically just a matter of install YAML through synaptic and then installing the RTM dependencies) as well as the email (I wanted to check gApps email, so I discovered it is the same URL, you just use the full email as the username -- I also discovered that wget did not like the https://username:password ... if the first of the password is numbers, so I took that out and added the wget switches "--http-user=$user --http-password=$pass") but they both work like a charm now.

Still no clue on the weather and system stats, though. I see absolutely nothing... and I'm certain that I made all of the necessary changes for weather.

Tomáš Kramár said...

If you have any problems, try running the configs separately.

Run

conky -c ~/.conky/conky_sys

and see what happens; if there is a problem, conky will probably tell you in its output.

For the weather: open the config, find the command, which is executing the weather script, copy it and run it in the terminal. That should give you some clue. Also, you need to register at weather.com, as the linked weather config tutorial suggests.

Anonymous said...

I do no have the ~/.conky/ directory. Can anyone help?

Anonymous said...

Thanks for the reply. I realize I can just create it, but you mentioned something about running the configs separately. Where are they? I am having some of the same issues others have had where it opens a bunch of system monitor windows. When closing any of them I get "XIO: fatal IO error 11 (Resource temporarily unavailable) on X server ":0.0"
after 2725 requests (2721 known processed) with 0 events remaining."
After digging into it I discovered that I didn't have the .conky directory so I figured that it was created somewhere in one of the supplied scripts which also put the configuration files in there, but I don't have any of this. I'd like to get conky worky but it seems I am missing something?

R.G.B. said...

Let's make this one a quick comment:
Looks great! I'll use it pretty soon! Thanks for the work! xD

Tomáš Kramár said...

@JPHlem: There is a ".conky" directory in the zip archive, where you can find all conky settings. It is a hidden file so you may not be able to see it. Try pressing CTRL + H in you file browser (that should generally show you hidden files, but it might not work in your file browser), or the safest way is to do

ls -la ~/.conky

Or maybe your archiver application didn't extract the file, because it was hidden. Try opening the archive again and make sure .conky is extracted.

Anonymous said...

svennipp:
error in conky_weather in .conky folder.

it refers to template under username kremso.

"TEXT
${execpi 1800 ~/scripts/conkyForecast --location=DAXX0009 --template=/home/kremso/scripts/conkyForecast.template}
"

Anonymous said...

Could you please upload a new link to the archive, I always get 404ed.

Anonymous said...

I very much liked what you designed and i want to try this

Please can this be upload somewhere ?


My Mail Contact

Anonymous said...

UPLOAD THIS AGAIN

Anonymous said...

Hello...do you still exist? Can you upload this again?

Kerala web designer said...

The way you customized is amazing, as a web designer am inspired a lot with your Linux designs and the new approach will guide lots of designers to test their skills in Linux envirnments.

Tüpbebek said...

I am happy to find this very useful for me, as it contains lot of information. I always prefer to read the quality content
00