Sunday, January 6, 2013

Ubuntu: File Managers

I am continuing to use Ubuntu as my primary desktop and I am loving it(I still use Windows desktop. It has it's advantages). As I get used to the environment, I am always looking to mimic familiar options from Windows. This time around I was looking to find out about adding applications to Context menu in Ubuntu. Like always, I stumbled on something bigger - File Manager(s).

Earlier I posted about Linux architecture and how different layers of the Operating System can be replaced/added. If you read that post, you will see how I struggled with Unity Desktop that came with Ubuntu 12.04  and eventually learned to replace it with Gnome desktop. Apparently, each desktop has it's own flavor of File Manager and then some.

If you are coming from the Windows world (like I did), here are some terminologies for you. What we call Windows in Windows Operating System (like Windows XP) is really the Desktop. We saw earlier there are many different Desktops including Gnome, KDE, Unity etc. The Desktops have several parts and one of them is a File Manager. This is called Windows Explorer (it used to be called File Manager in versions before Windows 95). There are choices for Explorer, but I've not seen many people replacing the Windows Explorer with another.

In Ubuntu (for that matter entire *nix [Unix, Linux]) world, everything is customizable and/or replaceable. I was able to replace my troubled Unity desktop with Gnome desktop and overcome some issues earlier. When I started researching on Context Menus, I stumbled on Nautilus package, which is the default File Manager in Gnome. Since Ubuntu 12.04 didn't support Gnome desktop natively, it didn't install Nautilus either. It had a File Manager called Thunar instead. And, when I installed Gnome, unknowingly, I had also opted for Nautilus, default file manager for Gnome. Apparently, there are at least 20 different File Managers available. See this blog.

This site has a nice picture of the Linux Architecture.

In Gnome Desktop, you get to File Manager by clicking on Places menu on top.

Workspace 1_057Fig 1: Menu to reach File Manager

Screenshot from 2013-01-06 19:06:37Fig 2: Nautilus File Manager

So what about Context Menu?
Coming back to adding context menu, it's done using Nautilus Actions.I had to install it first. (This you could do it in Ubuntu Software Center or use apt-get command). Once you installed it, you can add context menu items as shown below:

Nautilus Actions ConfigurationFig 3: Nautilus Actions Configuration

And of course, after changing the context menu you need to reload the Nautilus File Manager. To do this, you can type the below command:

<code>killall nautilus</code>

This kills all processes associated with the particular program (here nautilus). For Windows users, this is like going to Windows Task Manager and doing "End Program". See here for more on killall. Incidentally, they also talk about killing nautilus!!

Running KDiff3 from Context Menu
The program I was trying to add to context menu was KDiff3 (it's a great diff utility, try it, if you haven't already. I use it on Windows as well). Nautilus Actions allows you to add programs to the context menu. I select 2 files to be compared and right click to select and open KDiff3 and voilĂ ! KDiff3 opens and diff's the files automatically!

Nautilus Context MenuFig 4: Nautilus Context Menu


kdiff3_074Fig 5: Kdiff3 From Context Menu


References

  1. http://www.tuxarena.com/2011/06/20-file-managers-for-ubuntu/

  2. http://www.techdrivein.com/2010/05/what-is-nautilus-elementary-and-how-to.html

  3. https://live.gnome.org/Nautilus/Screenshots

  4. http://www.tellmeaboutlinux.com/content/linux-architecture

  5. http://en.wikipedia.org/wiki/File_manager

  6. http://askubuntu.com/questions/88480/adding-extra-options-to-right-click-menu

  7. http://www.omgubuntu.co.uk/2011/12/how-to-add-actions-emblem-support-back-to-nautilus-in-ubuntu-11-10/

  8. http://www.linfo.org/killall.html

No comments :

Post a Comment

I will be happy to hear your comments or suggestions about this post or this site in general.