CODE: script to register all subdir to mr