Re: Libtrash: Have any of you successfully activated it?

2011-04-25 Thread Klistvud

Dne, 25. 04. 2011 05:46:18 je Jason Hsu napisal(a):
I've been able to get libtrash to PARTIALLY work.  It only works on  
non-empty files and ONLY files deleted through the GUI.  Libtrash  
does NOT work for files deleted through the rm command.


What do I need to do to get for libtrash to work for files deleted  
through the rm command?  If this isn't possible, is there another  
package I can install to fill the gap?


http://penguinpetes.com/b2evo/index.php?title=why_can_t_we_throw_away_desktop_trashcanmore=1c=1tb=1pb=1

It won't exactly fill the gap, but is a funny read nonetheless.

Perhaps btrfs, with its roll-back capability, is what you're after. For  
the occasional undelete now and then, it's bound to be better than any  
userland trashcan implementation.


--
Cheerio,

Klistvud  
http://bufferoverflow.tiddlyspot.com
Certifiable Loonix User #481801  Please reply to the list, not to  
me.



--
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/1303721407.14909.2@compax



Re: Libtrash: Have any of you successfully activated it?

2011-04-25 Thread Bob McConnell

Klistvud wrote:

Dne, 25. 04. 2011 05:46:18 je Jason Hsu napisal(a):
I've been able to get libtrash to PARTIALLY work.  It only works on 
non-empty files and ONLY files deleted through the GUI.  Libtrash does 
NOT work for files deleted through the rm command.


What do I need to do to get for libtrash to work for files deleted 
through the rm command?  If this isn't possible, is there another 
package I can install to fill the gap?


http://penguinpetes.com/b2evo/index.php?title=why_can_t_we_throw_away_desktop_trashcanmore=1c=1tb=1pb=1 



It won't exactly fill the gap, but is a funny read nonetheless.

Perhaps btrfs, with its roll-back capability, is what you're after. For 
the occasional undelete now and then, it's bound to be better than any 
userland trashcan implementation.


I suspect the most likely solution is to rename rm and replace it with a 
script that moves files into the trash directory.


Bob McConnell
N2SPP


--
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org

Archive: http://lists.debian.org/4db54dd1.3090...@lightlink.com



Libtrash: Have any of you successfully activated it?

2011-04-24 Thread Jason Hsu
Installing Libtrash from Synaptic is easy enough.  However, I can't for the 
life of me figure out how to activate it.

From 
http://www.techrepublic.com/article/safely-delete-linux-files-with-libtrash/5034918
 , I'm supposed to add the following code (had to use a different file for the 
LD_PRELOAD command) to /etc/profile: 

export LD_PRELOAD=/usr/lib/libtrash/libtrash.so.2.4
alias trashon=”export TRASH_OFF=NO”
alias trashoff=”export TRASH_OFF=YES”

But entering trashon in the command line didn't work.

Adding that code to /home/(username)/.bashrc didn't work either.

Has ANYONE successfully implemented libtrash?

If libtrash is inherently ineffective, what are some lightweight alternatives I 
should use?

-- 
Jason Hsu jhsu802...@jasonhsu.com


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20110424154549.91e2273a.jhsu802...@jasonhsu.com



Re: Libtrash: Have any of you successfully activated it?

2011-04-24 Thread Ron Johnson

On 04/24/2011 03:45 PM, Jason Hsu wrote:

Installing Libtrash from Synaptic is easy enough.  However, I can't for the 
life of me figure out how to activate it.


From 
http://www.techrepublic.com/article/safely-delete-linux-files-with-libtrash/5034918
 , I'm supposed to add the following code (had to use a different file for the 
LD_PRELOAD command) to /etc/profile:


export LD_PRELOAD=/usr/lib/libtrash/libtrash.so.2.4
alias trashon=”export TRASH_OFF=NO”
alias trashoff=”export TRASH_OFF=YES”

But entering trashon in the command line didn't work.



Define didn't work.  Returned an error message?


Adding that code to /home/(username)/.bashrc didn't work either.

Has ANYONE successfully implemented libtrash?



Did you configure it properly?


If libtrash is inherently ineffective, what are some lightweight alternatives I 
should use?




--
Neither the wisest constitution nor the wisest laws will secure
the liberty and happiness of a people whose manners are universally
corrupt.
Samuel Adams, essay in The Public Advertiser, 1749


--
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org

Archive: http://lists.debian.org/4db4a730.4030...@cox.net



Re: Libtrash: Have any of you successfully activated it?

2011-04-24 Thread Jason Hsu
The files that I deleted or removed with rm didn't show up in the Trash 
folder.  I tried adding those commands to the /etc/profile file and the 
/home/(username)/.bashrc files, but that didn't work.

What's the proper way to configure libtrash?  Is it working on your computer?  
When you delete a file in the GUI or remove it with the rm command, does it 
show up in your Trash folder?

On Sun, 24 Apr 2011 17:41:52 -0500
Ron Johnson ron.l.john...@cox.net wrote:
 
 Define didn't work.  Returned an error message?
 
  Adding that code to /home/(username)/.bashrc didn't work either.
 
  Has ANYONE successfully implemented libtrash?
 
 
 Did you configure it properly?
 

-- 
Jason Hsu jhsu802...@jasonhsu.com


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20110424175424.4e964ed3.jhsu802...@jasonhsu.com



Re: Libtrash: Have any of you successfully activated it?

2011-04-24 Thread Ron Johnson

From the link that you so handily provided in your OP:

Configuring libtrash
Oddly enough, before you install libtrash, you must configure it. The 
libtrash-1.8/libtrash.conf file comes preconfigured with default 
settings. When libtrash is compiled, the /etc/libtrash.conf file is 
created, but this file only reflects the default configuration of libtrash.


That doesn’t mean you can’t reconfigure libtrash. It just takes a little 
extra work. There are two configurations available when libtrash is 
activated:


* Systemwide configuration: This is used for all users. This 
configuration is read from the /etc/libtrash.conf file.
* Personal configurations: Each user may use a separate 
configuration. Separate configurations are enabled through settings read 
from the .libtrash file in the home directory of each user.



Systemwide configuration
Systemwide settings are made through the /etc/libtrash.conf file. The 
required settings must be made prior to compiling libtrash. Changing the 
/etc/libtrash.conf file after compiling libtrash will not change the 
default behavior of the program. To enforce the idea that this file 
should never be edited, no users are given write permission to this 
file. The /etc/libtrash.conf file is a read-only file for all users, 
including root. Therefore, you’ll make changes to the 
libtrash-1.8/libtrash.conf file prior to installation.


There are four entries in the libtrash.conf that are used as 
environmental variables and cannot be changed by a user's personal 
configuration settings when libtrash is run. These four settings are:


* DEBUG
* PERSONAL_CONF_FILE
* WARNING_STRING
* UNCOVER_DIRS


The next four settings allow libtrash to intercept the standard routines 
Linux uses when files are unlinked or renamed. Your safest bet is to use 
the defaults for all of these settings:


* INTERCEPT_UNLINK= YES
* INTERCEPT_RENAME = YES
* INTERCEPT_FOPEN
* INTERCEPT_OPEN


More options, more control
The rest of options give you more control over libtrash. These options are:

* TRASH_CAN = Trash
  This entry sets the name for the subdirectory where deleted files 
will be stored. The default name for this directory is Trash. Any name 
may be used. To change the directory name, enter the new name without 
any slashes.

* IN_CASE_OF- FAILURE =
  This setting determines how libtrash reacts when there is a 
failure. Setting this value to PROTECT prevents files from being deleted 
by the standard Linux function. Setting the value to ALLOW_DESTRUCTION 
overrides libtrash.


* SHOULD-WARN = YES
  This setting enables a warning message for libtrash. It's 
normally a good idea to remind users that their files will be 
permanently deleted when libtrash is disabled. This is especially true 
if users on the system are new to Linux or for users who assume libtrash 
is always running.

* PROTECT_TRASH = YES
  This setting protects files in the trash from being deleted. 
Files placed in the user's trash represent a special case. Libtrash 
functions by sending deleted files to a trashcan in the user's home 
directory. When the user wants to delete files in the trashcan, the 
default libtrash doesn't work.

* IGNORE_ENTENSIONS =
  This setting allows you to specify files with specific extensions 
that may be deleted without being copied to the trashcan. To specify 
which types may be ignored by libtrash, create a semicolon delimited 
separated list of the file extensions to be ignored. Do not include a 
dot (.) before the extension. For example, to allow .o, .c, and log 
files to be deleted without being moved to the trashcan, use this entry: 
IGNORE_ENTENSIONS = o; c; log

* IGNORE_HIDDEN = YES
  Hidden files and files inside hidden directories may be sent to 
the trash. Setting this entry to YES allows Linux to delete hidden files 
without moving them to the trash. Stick with the default value of YES 
and override it if you must on a per-user basis.

* IGNORE_EDITOR_BACKUP = NO
  This entry will ensure that backups of important files are always 
sent to the trash. These are files that end with a tilde (~). The 
default is yes. Changing this setting might be a good idea.

* IGNORE-EDITOR-TEMPORARY = YES
  This entry concerns temporary files created by editors. Setting 
this entry to YES allows these temporary files to be removed without 
moving them to the trash. Set the entry to NO to allow libtrash to move 
these files to the user's trash. Stick with the default and change this 
setting on a per-user basis.

* LIBTRASH_CONFIG_FILE_UNREMOVEABLE = YES
  This entry provides protection for the user's personal libtrash 
configuration file. Removing your own configuration file will cause 
unexpected actions from libtrash. Leave this setting alone.

* TRASH_SYSTEM_ROOT
  The TRASH_SYSTEM_ROOT variable specifies the location of the 
directory under the trash that will function as the 

Re: Libtrash: Have any of you successfully activated it?

2011-04-24 Thread Jason Hsu
I've been able to get libtrash to PARTIALLY work.  It only works on non-empty 
files and ONLY files deleted through the GUI.  Libtrash does NOT work for files 
deleted through the rm command.

What do I need to do to get for libtrash to work for files deleted through the 
rm command?  If this isn't possible, is there another package I can install 
to fill the gap?


-- 
Jason Hsu jhsu802...@jasonhsu.com


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20110424224618.d55415af.jhsu802...@jasonhsu.com