Hacking Nautilus with G-Scripts
jay
While updating Wired HowTo Guide Linux Style I came across G-Script which is a collection of scripts for use in Gnome’s Nautilus file manager.
And as things go I was searching for a way to add shred to the context-menu of Nautilus just like you can with Thunar plug-ins and ended up finding a new toy to tinker with.
A nautilus script is just an executable shell script (usually bash) that is placed in a special scripts directory so that the Nautilus graphical shell can find it. This is a really neat function of Nautilus, because it allows you to extend the functionality of the file browser to do just about anything. ~ G-Script FAQ
Even though G-Scripts are easy to install, don’t be fooled their simplicity. These scripts can perform some pretty powerful actions, like encrypting files, creating archives and executing programs all from a context-menu.
![]()
You can download a collection of scripts here and the site also has links to other scripts as well as more scripts which are divided by functionality that are not included in the archive.
The sections are:
- Archiving
- Executing
- File Info
- File Processing
- Multimedia
- File System Management
- System Configuration
Once you’ve downloaded the archive; extract it to /home/user/.gnonme2/nautilus-scripts and that’s it.
Now open Nautilus, select a file or folder and right-click on it. The context menu will appear with an item titled Scripts, which has a sub-menu of all of the scripts in the nautilus-scripts folder.
The one script I wanted shred appears to be broken so I am working on my own hack for that.
One of the cool things about these scripts is that upon inspection of the source code they appear to be pretty easy to hack. And if you’ve done any bash scripting then you’ll be right at home.
![]()
I did some goolging for G-Scripts and most links linked back to the main site. This surprises me because G-Script is such a powerful, easy to implement and easy to hack feature that I am surprised there aren’t a lot more sites raving about it. The thing about G-Scripts that appeals to me is that I have the ability customize a small part of Linux beyond the usual GUI elements. I think it’s a really cool feature to be able to write a simple shell script for Nautilus that is actually of some use to me and maybe other people.
Posted in Linux, HOWTO, Tips N Tricks, GNOME |











August 9th, 2006 at 5:48 pm
Cab…
I am Karin, very interesting article that contained the information I was searching for in Google, thanks….
August 18th, 2007 at 3:04 pm
Thanks for the tips. There’s a small typo in one of the paths, though: “gonme2″
October 21st, 2007 at 4:08 pm
please tell me why, i’m feeling . Jumana Fanni.