Here are some small Python scripts I have written over time. Usually they are tested on a recent version of Ubuntu Linux
This scripts are distributed in the hope that they will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. You are free to do with them what ever you want.
Contents
nautilus-print
A very simple extension for Nautilus, the standard file manager for the GNOME desktop, to print files from the context menu.
It’s not very sophisticated and doesn’t give any error messages if something goes wrong. It doesn’t do any file type conversion but relies on what your print system can do - so don’t expect too much.
Requirements
nautilus-print needs:
-
libautilus-extension Python bindings
Tested with version 0.6.1 as distributed with Ubuntu 10.04 “Lucid Lynx”.
For Ubuntu that’s the package python-nautilus
-
Tested with version 1.2.7 as distributed with Ubuntu 10.04 “Lucid Lynx”.
For Ubuntu that’s the package gtklp
Download
Installation
Save the file as $HOME/.nautilus/python-extensions/nautilus-print.py and restart Nautilus (e.g. log out and log in or run nautilus --quit from the command line).
Usage
Right click on a local file in Nautilus. You should see a menu that somewhere has a Print item. Click on that to start GtkLP with the selected file(s).
—
addtorecent
A simple script to put documents on GNOME’s recently used document list
Download
Usage
addtorecent URI [MIME-type] [app] [cmd]
-
URL is the path or URI of the document
-
MIME-type is its MIME-type and defaults to text/plain
-
- app is a name of an application you want to associate with this document
-
and defaults to xdg-open
-
- cmd is the command line to start app
-
and defaults to xdg-open %F