Adds harness from 'revel/revel' and updates imports

This commit is contained in:
Brenden Soares
2014-10-28 22:22:43 -07:00
parent a11342d6e7
commit 9046edff96
8 changed files with 1720 additions and 3 deletions

View File

@@ -2,7 +2,7 @@ package main
import (
"github.com/revel/revel"
"github.com/revel/revel/harness"
"github.com/revel/cmd/harness"
"strconv"
)
@@ -59,11 +59,13 @@ func runApp(args []string) {
// If the app is run in "watched" mode, use the harness to run it.
if revel.Config.BoolDefault("watch", true) && revel.Config.BoolDefault("watch.code", true) {
revel.TRACE.Println("Running in watched mode.")
revel.HttpPort = port
harness.NewHarness().Run() // Never returns.
}
// Else, just build and run the app.
revel.TRACE.Println("Running in live build mode.")
app, err := harness.Build()
if err != nil {
errorf("Failed to build app: %s", err)