From 2c97008e3e49bd46fd37824b45bf09f9dfc19107 Mon Sep 17 00:00:00 2001 From: Upamanyu Sharma Date: Tue, 7 Feb 2023 20:36:42 -0500 Subject: [PATCH] update --- Makefile | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) diff --git a/Makefile b/Makefile index ab24212..427d2f4 100644 --- a/Makefile +++ b/Makefile @@ -22,20 +22,8 @@ LABS=" lab1 lab2a lab2b lab2c lab2d lab3a lab3b lab4a lab4b " "--exclude=src/main/mrworker" \ "--exclude=*.so" \ Makefile src; \ - if ! test -e api.key ; then \ - echo "Missing $(PWD)/api.key. Please create the file with your key in it or submit the $@-handin.tar.gz via the web interface."; \ - else \ - echo "Are you sure you want to submit $@? Enter 'yes' to continue:"; \ - read line; \ - if test "$$line" != "yes" ; then echo "Giving up submission"; exit; fi; \ - if test `stat -c "%s" "$@-handin.tar.gz" 2>/dev/null || stat -f "%z" "$@-handin.tar.gz"` -ge 20971520 ; then echo "File exceeds 20MB."; exit; fi; \ - cat api.key | tr -d '\n' > .api.key.trimmed ; \ - curl --silent --fail --show-error -F file=@$@-handin.tar.gz -F "key=<.api.key.trimmed" \ - https://6824.scripts.mit.edu/2023/handin.py/upload > /dev/null || { \ - echo ; \ - echo "Submit seems to have failed."; \ - echo "Please upload the tarball manually on the submission website."; } \ - fi; \ + if test `stat -c "%s" "$@-handin.tar.gz" 2>/dev/null || stat -f "%z" "$@-handin.tar.gz"` -ge 20971520 ; then echo "File exceeds 20MB."; rm $@-handin.tar.gz; exit; fi; \ + echo "$@-handin.tar.gz successfully created. Please upload the tarball manually on Gradescope."; \ else \ echo "Bad target $@. Usage: make [$(LABS)]"; \ fi