diff --git a/doc/how_to_run.md b/doc/how_to_run.md index fd13007..0e18a8f 100644 --- a/doc/how_to_run.md +++ b/doc/how_to_run.md @@ -12,7 +12,7 @@ Then access to `http://localhost:8080/` by your browser. The default administrator account is `root` and password is `root`. -Source code modification is detected and reloaded automatically. You can modify logging configuration by editing `src/main/resources/logback-test.xml`. +Source code modification is detected and reloaded automatically. You can modify logging configuration by editing `src/main/resources/logback-dev.xml`. Build war file -------- diff --git a/project/build.scala b/project/build.scala index 3c2543a..a6582df 100644 --- a/project/build.scala +++ b/project/build.scala @@ -4,6 +4,7 @@ import sbt._ import sbtassembly.AssemblyKeys._ import sbtassembly._ +import JettyPlugin.autoImport._ object MyBuild extends Build { val Organization = "gitbucket" @@ -69,6 +70,7 @@ ), play.twirl.sbt.Import.TwirlKeys.templateImports += "gitbucket.core._", javacOptions in compile ++= Seq("-target", "7", "-source", "7"), + javaOptions in Jetty += "-Dlogback.configurationFile=/logback-dev.xml", testOptions in Test += Tests.Argument(TestFrameworks.Specs2, "junitxml", "console"), javaOptions in Test += "-Dgitbucket.home=target/gitbucket_home_for_test", testOptions in Test += Tests.Setup( () => new java.io.File("target/gitbucket_home_for_test").mkdir() ), diff --git a/release/build.xml b/release/build.xml index 7746325..ee0865e 100644 --- a/release/build.xml +++ b/release/build.xml @@ -47,7 +47,7 @@ + includes="JettyLauncher.class,HttpsSupportConnector.class"/> diff --git a/src/main/resources/logback-dev.xml b/src/main/resources/logback-dev.xml new file mode 100644 index 0000000..efdb6ac --- /dev/null +++ b/src/main/resources/logback-dev.xml @@ -0,0 +1,26 @@ + + + + + %d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n + + + + + gitbucket.log + + %d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n + + + + + + + + + + + \ No newline at end of file diff --git a/src/main/resources/logback-test.xml b/src/main/resources/logback-test.xml deleted file mode 100644 index efdb6ac..0000000 --- a/src/main/resources/logback-test.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - - - %d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n - - - - - gitbucket.log - - %d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n - - - - - - - - - - - \ No newline at end of file