AWN, Xfce & working Trash

Last time I wrote about installing AWN in Debian. This time I’ll wrote about making AWN to work with Xfce’s wastebasket/trash. Here we go (:

The first thing that has to be done, is to point ~/.Trash folder into right place - and right place, according to trash spec, is in ~/.local/share/Trash/files folder.

~ mv ~/.Trash ~/.Trash_old

This one will move ~/.Trash into ~/.Trash_old. Now it’s time to create symlink:

~ ln -s ~/.local/share/Trash/files ~/.Trash

That should do the thing. I assume you don’t use Nautilus in Xfce (if you are, firstly backup file /usr/bin/nautilus) so you have to create /usr/bin/nautilus:

# gedit /usr/bin/nautilus

You can use any other text editor, for example mousepad, vim etc., really (:

Now, put into that file the following content:

#!/bin/sh
#
# /usr/bin/nautilus
#
# Avant Window Navigator Trash Aplet Hack for KDE
# Adapted into Xfce by Hadret (http://en.hadret.com)
#
# Copyleft 2008 A. Tres Finocchiaro
#
# This script is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation

if [ "$1" = "trash:" ]; then
	exec thunar "$@/"
else
	exec thunar "$@"
fi

exit 0

It needs to be executable, so type:

# chmod +x /usr/bin/nautilus

That’s all, it should now work as you can see on video below (:


Video 1. AWN, Xfce & working Trash
(Here is same video in higher resolution)

Sweet, isn’t it? Who would thought, that all of this is just because GNOME doesn’t follow trash spec and AWN isn’t flexible enough (at least for now), to support any desktop environment [:

Regards

This one wouldn’t exist if there wouldn’t be this post on UbuntuForums. I’ve adapted it into Xfce and repaired command with creating symlink (:

Video

Was made using recordmydesktop about which small review you can read here. It’s in Debian Testing and Unstable repository.

Questions?

Post them in comments, if have some.

2 Responses to “AWN, Xfce & working Trash”


  1. Gravatar Icon 1 Mark Lee

    Hi,

    I’m a developer for Awn who happens to use Xfce as my desktop environment of choice, and is working on non-Gnome support for both the dock and the applets. Could you file a bug in the awn-extras project on Launchpad so that I can remember to attempt to get the trash applet working on non-Gnome environments?

    Thanks, and I hope that you’re enjoying Awn!

  2. Gravatar Icon 2 Hadret

    Yep, I enjoy it a lot. When I find some spare time, I’ll fill bug in Launchpad - not today I believe, cause I’m taking an exam -.-’

    Cheers for your comment (:

Leave a Reply