Date: 22 Dec 2004 08:51:09 -0500 From: Lowell Gilbert <freebsd-questions-local@be-well.ilk.org> To: Mike Jeays <Mike.Jeays@rogers.com> Cc: freebsd-questions@freebsd.org Subject: Re: Copying a directory hierarchy Message-ID: <44is6utp9u.fsf@be-well.ilk.org> In-Reply-To: <1103685781.33623.9.camel@chaucer> References: <1103680952.33623.2.camel@chaucer> <16840.55078.815394.941348@jerusalem.litteratus.org> <1103685781.33623.9.camel@chaucer>
next in thread | previous in thread | raw e-mail | index | archive | help
Mike Jeays <Mike.Jeays@rogers.com> writes:
> On Tue, 2004-12-21 at 21:08, Robert Huff wrote:
> > Mike Jeays writes:
> >
> > > How does on copy a complete directory hierarchy, including any hidden
> > > files?
> > >
> > > "cp -rp" leaves them out.
> >
> > cp -rp *
> > cp -rp .*
> This doesn't copy hidden files in lower-level directories, only in the
> top level. Thanks for the suggestion - a good idea that doesn't quite
> do it.
It works for me...
temp> type -a rm
rm is /bin/rm
temp> mkdir -p a/b/c/d/e
temp> touch a/b/c/d/.hidden a/b/c/d/e/.hidden-too
temp> cp -r a f
temp> find a f
a
a/b
a/b/c
a/b/c/d
a/b/c/d/e
a/b/c/d/e/.hidden-too
a/b/c/d/.hidden
f
f/b
f/b/c
f/b/c/d
f/b/c/d/e
f/b/c/d/e/.hidden-too
f/b/c/d/.hidden
temp>
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?44is6utp9u.fsf>
