[Gllug] help deleting file

Nix nix at esperi.org.uk
Sat Feb 18 21:31:39 UTC 2006


On Sat, 18 Feb 2006, Tethys said:
> 
> Nix writes:
> 
>>(The correct solution, as others have posted, is --, which is
>>interpreted by rm.)
> 
> Or for those old fogies among us, "rm ./--whatever". Traditionally

Yeah, that has a huge disadvantage though: command-line filename
completion and wildcard expansion generally strip the ./ again, and I
hardly ever type in filenames without using at least *one* of those.

> (pre GNU rm), you could give a single dash as a special argument
> to signify that the next filename began with a dash. But it wasn't
> supported everywhere IIRC, so prepending the path was the portable
> way to do it.

-- landed in POSIX in the end; I'm not sure if GNU was the first to
come up with it though.

-- 
`... follow the bouncing internment camps.' --- Peter da Silva
-- 
Gllug mailing list  -  Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug




More information about the GLLUG mailing list