#!/usr/bin/env python

import sys
import os

from os import path


def lndir(src, dst):
    root = path.abspath(src)
    for d, _, files in os.walk(src):
        shadow_dir = path.join(dst, d[len(root)+1:])
        if not path.exists(shadow_dir):
            os.makedirs(shadow_dir)
        for f in files:
            print "%s -> %s" % (path.join(d, f), path.join(shadow_dir, f))
            os.symlink(path.join(d, f), path.join(shadow_dir, f))


if __name__ == '__main__':
    lndir(sys.argv[1], sys.argv[2])

