1

I remember that there is an utility for GNU/Linux, that given some directory, builds the same directory hierarchy, but with all regular files replaced by symlinks to the corresponding ones.

I can't remember its name.

Yes, I know it's a simple lesson in shell programming, but no reason to reinvent the wheel.

slhck
  • 223,558
  • 70
  • 607
  • 592
KAction
  • 349
  • 1
  • 3
  • 12
  • 2
    Possible duplicate of [Create symlinks recursively for a whole tree](http://superuser.com/questions/356804/create-symlinks-recursively-for-a-whole-tree) – cfi Apr 06 '16 at 08:16

2 Answers2

2

cp has a -s flag, which makes symlinks, instead of copying. You can probably combine it with -r, so it recursively links everything, eg.:

cp -rs ./folder ./target/
K. Norbert
  • 692
  • 2
  • 5
  • 12
0

How about some command-line fu? There are a number of ideas on that page.

uSlackr
  • 8,955
  • 31
  • 48