First, you must have gradle installed. (Use brew.)
git clone <repository_url>
cd <repository_name>
curl https://raw.githubusercontent.com/WeCanCodeIT/gradle-scripts/master/application-plugin/simple.gradle --output build.gradle
gradle run -Papp=<main_class_name>
<main_class_name>
must include the package, if any.
If they've followed the instructions regarding what to name their app class, have the proper folder structure, etc this should be the same apart from the repository url for every student. At some point, I can pull this into a shell script.
Here's an example from the repository we put our in-class work into today
(https://github.com/btforsythe/cooker-polymorphism-example). The class name with the main
method is cooker.CookerApp
:
git clone https://github.com/btforsythe/cooker-polymorphism-example
cd cooker-polymorphism-example
curl https://raw.githubusercontent.com/WeCanCodeIT/gradle-scripts/master/application-plugin/simple.gradle --output build.gradle
gradle run -Papp=cooker.CookerApp