From owner-freebsd-newbies Fri Aug 3 6:16:59 2001 Delivered-To: freebsd-newbies@freebsd.org Received: from cindrpmx1.corp.harris.com (cindrpmx1.corp.harris.com [137.237.241.23]) by hub.freebsd.org (Postfix) with ESMTP id 3DFC937B403 for ; Fri, 3 Aug 2001 06:16:56 -0700 (PDT) (envelope-from rpotts@harris.com) Received: by cindrpmx1.corp.harris.com with Internet Mail Service (5.5.2653.19) id ; Fri, 3 Aug 2001 09:16:50 -0400 Message-ID: <95B669A7D872D41182A600508BDFFB8C01BECD3E@mlbmx7.ess.harris.com> From: "Potts, Ross" To: 'David Johnson' , leegold Cc: freebsd-newbies@freebsd.org Subject: RE: Recursively copying a directory - explain please. Date: Fri, 3 Aug 2001 09:16:46 -0400 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain; charset="iso-8859-1" Sender: owner-freebsd-newbies@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org Make SURE there are no links back to something already copied, i.e.: /fubar/dir1 /fubar/dir1/a/link1(link to ../dir1) and so on. I caught hell trying to clean up for a demo. Just went and started tarring away before realizing I had filled a 20 gig drive with nothing but recursive links. Even thought I didn't create the links, I still should have caught them right away. -----Original Message----- From: David Johnson [mailto:djohnson@acuson.com] Sent: Thursday, August 02, 2001 5:57 PM To: leegold Cc: freebsd-newbies@freebsd.org Subject: Re: Recursively copying a directory - explain please. leegold wrote: > > Please explain what the difference is between copying > a directory vs. Recursively copying a directory. Copying a directory only copies the directory and the files contained within it. Recursively copying a directory does the same thing, and in addition, copies any subdirectories (also recursively). The following diagram may be useful /fubar/testone /fubar/testtwo /fubar/subdir /fubar/subdir/example /fubar/subdir/sample /fubar/subdir/newdir /fubar/subdir/newdir/adinfinitem A "cp /fubar/*" will only copy the first two items. A "cp -r /fubar/*" will copy all of the above items. David To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-newbies" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-newbies" in the body of the message