From: Detlev Zundel Date: Fri, 15 Feb 2008 16:37:43 +0100 Subject: [U-Boot-Users] Delete all env vars except read onlys In-Reply-To: <20080213231143.C28F8243A7@gemini.denx.de> (Wolfgang Denk's message of "Thu, 14 Feb 2008 00:11:43 +0100") References: <20080213231143.C28F8243A7@gemini.denx.de> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi, > In message <47B37791.3010109@freescale.com> you wrote: >> >> > Oops??? "rm" never asks unless you ask it to ask. >> >> Not true. It will ask if you don't have write permission to the file, >> even if you are able to delete because you have write permission to the >> directory. > > Does it? Indeed. Must be a GNUism. I bet this was't there in Unix v6 > when I learned it ;-) > > > You are right, but this is still a special case where another, > explicit protection is being overwritten. * mkfs.ext2 on a file, needs -F package managers with unfulfilled * dependencies always ask and need a "--force-xxx" to go ahead whatsoever. * bzip2, bunzip2, bzcat, gzip, gzcat, gunzip -f to overwrite files * git-checkout-index needs -f to overwrite files * git-push needs -f to push non-linear head * git-fetch needs -f in same situtation * rsync -force to force deletion of dirs even if not empty .... I'll stop here. It seems the unix commandline tilted to a behaviour where interactive commands tend to ask in dangerous situations but scripts can explicitely override it - which is definitely what I prefer. Cheers Detlev -- Woman who seek to be equal with men lack ambition -- Timothy Leary -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu at denx.de