From 989d19b6c965ad4448aff15a01678f461241884f Mon Sep 17 00:00:00 2001 From: Gregory Rudolph Date: Sat, 19 Sep 2020 20:30:01 -0400 Subject: [PATCH] Added Makefile for convenience --- Makefile | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 Makefile diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..44252fe --- /dev/null +++ b/Makefile @@ -0,0 +1,27 @@ +JCC = javac + +JFLAGS = -g + +default: + @echo \"make build\" to compile Java classes + @echo \"make run\" to run Driver class + @echo \"make jar\" to compile executable jar + @echo \"make clean\" to clean up artifacts +build: + $(JCC) $(JFLAGS) Driver.java +run: + $(JCC) $(JFLAGS) Driver.java + java Driver +jar: + $(JCC) $(JFLAGS) Driver.java + @echo "Manifest-Version: 1.0" > manifest.txt + @echo "Class-Path: ." >> manifest.txt + @echo "Main-Class: Driver" >> manifest.txt + @echo "" >> manifest.txt + jar -cmf manifest.txt MTGClone.jar *.class + $(RM) manifest.txt + $(RM) *.class +clean: + $(RM) *.class + $(RM) manifest.txt + $(RM) MTGClone.jar