Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!zaphod.mps.ohio-state.edu!lavaca.uh.edu!menudo.uh.edu!sugar!ficc!peter From: peter@ficc.ferranti.com (Peter da Silva) Newsgroups: comp.unix.shell Subject: Re: copying files Keywords: cp Message-ID: Date: 7 Dec 90 22:29:39 GMT References: <1990Dec3.215656.8961@en.ecn.purdue.edu> <1990Dec5.021951.28104@en.ecn.purdue.edu> <1990Dec5.224655.29706@informix.com> Reply-To: peter@ficc.ferranti.com (Peter da Silva) Organization: Xenix Support, FICC Lines: 27 In article <1990Dec5.224655.29706@informix.com> dberg@informix.com (David I. Berg) writes: > In article <1990Dec5.021951.28104@en.ecn.purdue.edu> nichols@en.ecn.purdue.edu (Scott P Nichols) writes: > >Do any of you UNIX wizards know how to even list all of > >the names of the files which begin '.' (besides, of course > >the files in the root (second line of list) > > ls .[a-zA-Z1-9]* % touch ., % ls .[a-zA-Z1-9]* % ls -a . .. ., % I'm not sure what the original poster meant to ask. I assume it was "how to list all files but . and ..". We've had flame wars about this before. I think something like ".[^.]*" will work. If you're not sure the safest thing to do is... % ls -ad | sed -e '/^\.$/d' -e '/^\.\.$/d' ., % In practice, I find that ".??*" is the quickest pattern to type that gets most of them. -- Peter da Silva. `-_-' +1 713 274 5180. 'U` peter@ferranti.com