X-Git-Url: http://mj.ucw.cz/gitweb/?a=blobdiff_plain;f=mop%2Fadmin%2Fmo-grab-remote.sh;h=167532efb39f1e542ead28a7b2d480d1bfd8e1cf;hb=e2aa7da60d1e5a242ee780cf90ff347434227064;hp=6181b4e25b9d78988ca126fbe3ec3f69a6ecd8b3;hpb=fc833e30d9b1315ffdeb780d5257e8e1bdafad43;p=moe.git diff --git a/mop/admin/mo-grab-remote.sh b/mop/admin/mo-grab-remote.sh index 6181b4e..167532e 100755 --- a/mop/admin/mo-grab-remote.sh +++ b/mop/admin/mo-grab-remote.sh @@ -1,16 +1,18 @@ #!/bin/bash +# Grab all submits from the submit server and copy them to solutions/. [ -n "$1" ] || { echo "Usage: mo-grab-remote " ; exit 1 ; } -[ -f config ] || { echo "Missing config file, check cwd." ; exit 1 ; } +[ -f cf/mop ] || { echo "Missing config file, check cwd." ; exit 1 ; } set -e -. config +. cf/mop +rsync -a mo-submit@mo100:solutions/ submits for user in `bin/mo-get-users` ; do echo -n "$user:" mkdir -p solutions/$user for t in $@ ; do rm -rf solutions/$user/$t - D=$MO_ROOT/eval/submit/solutions/$user/$t + D=submits/$user/$t if [ -d $D ] ; then echo -n " $t" cp -a $D solutions/$user/$t