Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 28 Jan 2006 17:33:04 -0600
From:      Kirk Strauser <kirk@strauser.com>
To:        freebsd-questions@freebsd.org
Subject:   Re: rm - Argument list too long
Message-ID:  <200601281733.47099.kirk@strauser.com>
In-Reply-To: <9873AD032E93C851484DF81B@utd59514.utdallas.edu>
References:  <927ad6550601271534r17a6ddb2jd90b930f744d170f@mail.gmail.com> <9873AD032E93C851484DF81B@utd59514.utdallas.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
--nextPart1834166.81AvPFpyEV
Content-Type: text/plain;
  charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

On Friday 27 January 2006 17:52, Paul Schmehl wrote:
> for files in *.*
> do
> rm $files
> done

Don't ever, *EVER* blindly unlink glob expansions.  It's bad for you.

Instead, use something like:

    find . -name 'sess.*' -delete
=2D-=20
Kirk Strauser

--nextPart1834166.81AvPFpyEV
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (FreeBSD)

iD8DBQBD2/9a5sRg+Y0CpvERAtDNAKCPVTU4S+gEoBSxJsX9WwSULYUOvQCdH7Pl
1q9xGXIpwKUf5aXagB5huRg=
=OrhP
-----END PGP SIGNATURE-----

--nextPart1834166.81AvPFpyEV--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200601281733.47099.kirk>