From owner-freebsd-questions@FreeBSD.ORG Wed Feb 14 20:27:26 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A2CDC16A401 for ; Wed, 14 Feb 2007 20:27:26 +0000 (UTC) (envelope-from oregnier@steelbox.org) Received: from 27.mail-out.ovh.net (27.mail-out.ovh.net [213.186.38.137]) by mx1.freebsd.org (Postfix) with SMTP id 0680113C491 for ; Wed, 14 Feb 2007 20:27:25 +0000 (UTC) (envelope-from oregnier@steelbox.org) Received: (qmail 7288 invoked by uid 503); 14 Feb 2007 20:29:16 -0000 Received: from b6.ovh.net (HELO mail178.ha.ovh.net) (213.186.33.56) by 27.mail-out.ovh.net with SMTP; 14 Feb 2007 20:29:16 -0000 Received: from b0.ovh.net (HELO queue-out) (213.186.33.50) by b0.ovh.net with SMTP; 14 Feb 2007 20:27:26 -0000 Received: from mac76-2-82-241-6-173.fbx.proxad.net (HELO ?192.168.1.2?) (postmaster@steelbox.org@82.241.6.173) by ns0.ovh.net with SMTP; 14 Feb 2007 20:27:24 -0000 Message-ID: <45D371C5.9010905@steelbox.org> Date: Wed, 14 Feb 2007 21:32:05 +0100 From: Olivier Regnier User-Agent: Thunderbird 1.5.0.9 (Windows/20061207) MIME-Version: 1.0 To: freebsd-questions@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Ovh-Remote: 82.241.6.173 (mac76-2-82-241-6-173.fbx.proxad.net) X-Ovh-Local: 213.186.33.20 (ns0.ovh.net) X-Spam-Check: DONE|H 0.5/N Subject: Idesk - trash icon X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Feb 2007 20:27:26 -0000 Hello, I installed Idesk to show differents icons on my desktop with Openbox 3 and FreeBSD 6.2. I have a file called trash.lnk with the content: table Icon Caption: Trash Icon: /home/olivier/.idesktop/icons/emptytrash.png Width: 48 Height: 48 X: 347 Y: 660 Command[0]: thunar trash:/// Command[1]: /home/olivier/.scripts/./checktrash.sh end and here my script called checktrash.sh : (for the moment, I do not erase any files. I test only the presence of files and i post the good icon on the desktop. #!/bin/sh ls -A /home/olivier/.local/share/Trash/files/ | grep . >/dev/null if [ $? -eq 0 ]; then perl -i.bak -pe 's/emptytrash/fulltrash/g' /home/olivier/.idesktop/trash.lnk else perl -i.bak -pe 's/fulltrash/emptytrash/g' /home/olivier/.idesktop/trash.lnk fi When i launch Openbox, the script works fine but i have a problem when i empty the trash with the mouse, idesk doesn't put up-to-date my icon. Can you help me please ? Thank you :) -- Cheers, Olivier Regnier