baslinux AT lists.ibiblio.org
Subject: Baslinux mailing list
List archive
- From: James Miller <jamtat AT mailsnare.net>
- To: baslinux AT lists.ibiblio.org
- Subject: Re: [BL] helpful alias for newbies
- Date: Wed, 15 Oct 2003 11:33:13 -0500 (CDT)
On Wed, 15 Oct 2003, James Miller wrote:
> Reading over an article on filesystem checking, I ran across what looks
> like a really helpful alias for a much used Linux system command - rm. It
> links rm to rm -i , which asks the user for confirmation before deleting
> any file with the rm command. To set up the alias on your system do
> -----------------
> alias rm='rm -i'
> -----------------
> After you do this, any time you issue "rm fileuwannadelete.txt" you get a
> response from the system "rm: remove 'fileuwannadelete.txt'?" Press
> "n" or "y" keys accordingly.
>
Oops. Reading further in that article I discovered a nice little script
(apart from the comments in Danish contained in the script) called
"saferm." I decided to put that on my system and to alias it to the
"del" command. In the process I discovered that Steven has already
aliased the del command to "rm -i". So, I discovered something new about
BL that sort of obviates the alias I offered in my original post. But do
take a look at the saferm script: it creates a .trash dir in the home
directory to which it moves things when you run saferm or (in my
case) del. You can then go in later and really delete things from that
dir. Something for those who want to be extra careful about deleting
things from their Linux system. This is along the lines that Win does
deleting, with its trash folder which must be emptied from time to time.
James
-
[BL] helpful alias for newbies,
James Miller, 10/15/2003
- Re: [BL] helpful alias for newbies, James Miller, 10/15/2003
Archive powered by MHonArc 2.6.24.