marking4/tails
author Christian Urban <urbanc@in.tum.de>
Wed, 07 Aug 2019 16:15:42 +0100
changeset 273 b19227660752
parent 246 178438912e5f
permissions -rwxr-xr-x
updated
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
246
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     1
#!/bin/sh
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     2
###set -e
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     3
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     4
trap "exit" INT
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     5
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     6
files=${1:-assignment20189-*}
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     7
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     8
for sd in $files; do
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     9
  cd $sd
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    10
  #echo $sd
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    11
  marksone=$(( `tail -1 output` ))
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    12
  markstwo=$(( `tail -1 output1` ))
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    13
  if [ "$marksone" != "$markstwo" ]; then
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    14
      echo $sd + "is different"
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    15
  fi
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    16
  cd ..
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    17
done
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    18
178438912e5f updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    19