|
Home > Archive > Unix Programming > May 2006 > create a mirror: directories created, files linked
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
create a mirror: directories created, files linked
|
|
|
| I need to mirror a directory structure and create links for the files.
THere will be no links embedded. I'm assuming that I can do this with
find in 2 steps
1. create the linktree directory structure.
find SOURCE_TREE -type d -exec mkdir -p LINK_TREE/- {} \;
2. create links to files
find SOURCE_TREE -type f -exec ln -s LINKTREE/- - {} \;
Not sure about the syntax. That is where I need the help.
| |
|
| In article <1147368866.163157.32200@j73g2000cwa.googlegroups.com>,
billy <bp1497@att.com> wrote:
>I need to mirror a directory structure and create links for the files.
>THere will be no links embedded. I'm assuming that I can do this with
>find in 2 steps
>1. create the linktree directory structure.
> find SOURCE_TREE -type d -exec mkdir -p LINK_TREE/- {} \;
>2. create links to files
> find SOURCE_TREE -type f -exec ln -s LINKTREE/- - {} \;
>Not sure about the syntax. That is where I need the help.
man lndir
| |
|
|
|
|
|