2 # Mirror directory tree from remote to local server, keeping the path.
7 expect_n_args 2 "(server, directory)" "$@"
10 path_package=/tmp/delete.tar
15 ssh plom@"${server}" "cd \"${dir}\" && tar cf ${path_package} ."
16 scp plom@"${server}":"${path_package}" "${path_package}"
19 tar xf "${path_package}"
22 ssh plom@"${server}" rm "${path_package}"