X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?p=chiark-utils.git;a=blobdiff_plain;f=scripts%2Fcvs-repomove;h=92e1765bc371f56197ae617cbf681ce9f4d563aa;hp=62f850ef6037c85ab5ea7d9e8888ec2aca64439e;hb=d0ad56266745f3f3368c1d188d2d9b051e28b5e4;hpb=18fc78da528c903ba181ccb4b7cfb90d94e9cbad diff --git a/scripts/cvs-repomove b/scripts/cvs-repomove index 62f850e..92e1765 100755 --- a/scripts/cvs-repomove +++ b/scripts/cvs-repomove @@ -115,11 +115,21 @@ do_move () { fi for f in $module..*; do case \"\$f\" in - *..moved-to-*) echo \" btw, module was previously at destn repo\" ;; + *..moved-to-*) + echo \" btw, module was previously at destn repo\" + mv -- \"\$f\" \ + \"\${f/..moved-to-/..previously-\$(date +%s)-moved-to-}\" + ;; *..previously-*) ;; - *..tmp-*) echo \" nb: possibly-stale temp/partial copy \$f\" ;; - *..\*) ;; - *) echo >&2 \"error: found unexpected subdir \$f\"; exit 8;; + *..tmp-*) + echo \" nb: possibly-stale temp/partial copy \$f\" + ;; + *..\*) + ;; + *) + echo >&2 \"error: found unexpected subdir \$f\" + exit 8 + ;; esac done '" @@ -176,7 +186,7 @@ do_furtle () { remotehost="${goose%%:*}" path="${goose#*:}" check_hostname "$remotehost" - check_remote_path "$remotepath/$module" + check_remote_path "$path/$module" isremote=true compute_fqdn_data "$remotehost" if [ "x$fqdn_data" = "x$our_fqdn_data" -a \