Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
Minimal Play! Application
#!/bin/bash
APP_NAME=$1
if [[ -z $APP_NAME ]]
then
me=`basename "$0"`
echo "App name is required. Use $me <app-name>"
exit 1
fi
mkdir $APP_NAME
cd $APP_NAME
echo "Boostraping Play app in `pwd`"
cat << EOF > build.sbt
name := """$APP_NAME"""
version := "1.0-SNAPSHOT"
lazy val root = (project in file(".")).enablePlugins(PlayScala)
scalaVersion := "2.11.7"
resolvers += "scalaz-bintray" at "http://dl.bintray.com/scalaz/releases"
EOF
mkdir project
cat << EOF > project/plugins.sbt
// The Play plugin
addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.5.4")
EOF
cat << EOF > project/build.properties
sbt.version=0.13.11
EOF
mkdir conf
touch conf/application.conf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment