Re: Flag to override 'cp' of symbolic links

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thnaks,

I fixed it by using a -H flag with cp.

Paul

On Thu, 2003-11-06 at 10:10, Volker Kroll wrote:
> On Thu, 2003-11-06 at 10:50, Paul Barclay wrote:
> > What is the flag the makes cp copy the file and not the symbolic link?
> > 
> > I don't want a hard liked file I want to copy the symbolic link and have
> > a distinct file after the operation.
> 
> Hi, 
> 
> try this:
> 
> my dir to copy from:
> 
> Thu Nov 06 11:07:39 kroll@bach:~> ls -l test
> total 4
> lrwxrwxrwx    1 kroll    kroll           3 Nov  6 11:06 B -> bla
> -rw-rw-r--    1 kroll    kroll          41 Nov  6 11:07 bla
> 
> my dir to copy to:
> Thu Nov 06 11:08:40 kroll@bach:~> ls -l test1/
> total 0
> 
> now give the -L a try
> 
> Thu Nov 06 11:08:46 kroll@bach:~> cp -L test/* test1/
> 
> tada, and now:
> Thu Nov 06 11:09:03 kroll@bach:~> ls -l test1/
> total 8
> -rw-rw-r--    1 kroll    kroll          41 Nov  6 11:09 B
> -rw-rw-r--    1 kroll    kroll          41 Nov  6 11:09 bla
> 
> HTH
> Volker
> 


________________________________________________________________________

E-mail is an informal method of communication and may be subject to data corruption, interception and unauthorised amendment for which Digital Bridges Ltd will accept no liability. Therefore, it will normally be inappropriate to rely on information contained on e-mail without obtaining written confirmation.

This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden.

________________________________________________________________________


-- 
redhat-list mailing list
unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/redhat-list

[Index of Archives]     [CentOS]     [Kernel Development]     [PAM]     [Fedora Users]     [Red Hat Development]     [Big List of Linux Books]     [Linux Admin]     [Gimp]     [Asterisk PBX]     [Yosemite News]     [Red Hat Crash Utility]


  Powered by Linux