[Gllug] cp real files but not links

David L Neil Mailing list a/c GLLUG at getaroundtoit.co.uk
Wed Feb 25 15:14:28 UTC 2009


Is it possible to copy a directory's contents (and sub-directories) to a
new location, but only the 'real files' and not any symlinks?

I was probably remembering something like this:
	cp -rv --no-dereference ../original/* /copy
but that's not what the option (or -P) means. Duh!

NB the files which are linked-to, in yet another directory, are to
remain untouched. There are a reasonably large number of files and links
in the mix.

I'm sure I knew how to do this - once - but perhaps on another command
line, another operating system, another brain, another time, another
planet...

Any ideas please?
=dn
-- 
Gllug mailing list  -  Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug




More information about the GLLUG mailing list