Book Image

Scala for Java Developers

By : Thomas Alexandre
Book Image

Scala for Java Developers

By: Thomas Alexandre

Overview of this book

Table of Contents (19 chapters)
Scala for Java Developers
Credits
Foreword
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
Index

Getting started with the Typesafe Activator


Using the same method that we used earlier in the book to create projects based on the Activator templates, getting started with a Play project through the Activator is very straightforward. Just go to the Typesafe Activator installation directory and enter the following command:

> ./activator ui

This will launch the activator in a browser window. The most basic Scala Play project is found in the hello-play-scala template. Once you have selected the template, notice the default location that indicates where the project will be created and then click on Create.

Let's run our sample project either directly from the activator browser view or from a terminal window by navigating to the root directory of the created project and entering the following command in the command prompt:

> ./activator run

Once the server is listening on port 9000, you can open the http://localhost:9000/ URL in a browser. Compilation is triggered only once you access the...