Date: Fri, 3 Jan 2003 10:25:02 -0500 From: "David S. Jackson" <deepbsd@earthlink.net> To: mike <mike@labs.unixhideout.com> Cc: freebsd-questions@FreeBSD.ORG Subject: Re: Shell guru needed. Message-ID: <20030103152501.GA1925@sylvester.dsj.net> In-Reply-To: <200301030103.h0313b67012698@labs.unixhideout.com> References: <200301030103.h0313b67012698@labs.unixhideout.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Jan 02, 2003 at 08:03:37PM -0500 mike <mike@labs.unixhideout.com> wrote: > Hey guys. heres the skinny. I have a huge library and i want to > organize it. I want find to go through recursively, and move any "pdf" > files it finds to a certain directory. I need an example piece of > script on how i would confront this. It will save me hours if not days > so thanks in advance. Can't believe no one has used xargs yet... find /path/to/messydir -name '*.pdf' -type f | xargs -I % mv \ /path/to/messydir/% /path/to/newdir/% -- David S. Jackson dsj@dsj.net =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Don't worry about the world coming to an end today. It's already tomorrow in Australia. -- Charles Schulz To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030103152501.GA1925>