TDT4255/deliver.sh
Peter Aaser da05c8924c
Update deliver.sh
Fixed oopsie
2019-10-07 17:44:16 +02:00

27 lines
671 B
Bash
Executable file

#!/bin/bash
read -p "Enter your student username (the one you use on badboard): " username
echo "Cleaning your project"
# ./sbt.sh clean
echo "Creating archive"
mkdir wrap
mkdir wrap/project
cp -r src ./wrap/
cp build.sbt ./wrap
cp project/Dependencies.scala ./wrap/project/Dependencies.scala
cp project/build.properties ./wrap/project/build.properties
cp sbt.sh ./wrap
(cd ./wrap/; tar czfv $username.tar.gz .)
mv ./wrap/$username.tar.gz .
rm -rf ./wrap
echo "Unwrapping and testing your wrapped package"
mkdir wrapTest
tar -C ./wrapTest -xvf $username.tar.gz
./wrapTest/sbt.sh test
rm -rf ./wrapTest
echo "If the test output looked good then you're good to go!"