Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
S
spring-boot
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DEMO
spring-boot
Commits
28ed59ca
Commit
28ed59ca
authored
Oct 11, 2016
by
Stephane Nicoll
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Polish contribution
Closes gh-6645
parent
3cccc732
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
11 additions
and
8 deletions
+11
-8
RunProcess.java
...ava/org/springframework/boot/loader/tools/RunProcess.java
+1
-1
AbstractRunMojo.java
.../java/org/springframework/boot/maven/AbstractRunMojo.java
+3
-2
RunMojo.java
...src/main/java/org/springframework/boot/maven/RunMojo.java
+1
-1
StartMojo.java
...c/main/java/org/springframework/boot/maven/StartMojo.java
+6
-4
No files found.
spring-boot-tools/spring-boot-loader-tools/src/main/java/org/springframework/boot/loader/tools/RunProcess.java
View file @
28ed59ca
...
@@ -77,7 +77,7 @@ public class RunProcess {
...
@@ -77,7 +77,7 @@ public class RunProcess {
protected
int
run
(
boolean
waitForProcess
,
Collection
<
String
>
args
)
protected
int
run
(
boolean
waitForProcess
,
Collection
<
String
>
args
)
throws
IOException
{
throws
IOException
{
ProcessBuilder
builder
=
new
ProcessBuilder
(
this
.
command
);
ProcessBuilder
builder
=
new
ProcessBuilder
(
this
.
command
);
builder
.
directory
(
workingDirectory
);
builder
.
directory
(
this
.
workingDirectory
);
builder
.
command
().
addAll
(
args
);
builder
.
command
().
addAll
(
args
);
builder
.
redirectErrorStream
(
true
);
builder
.
redirectErrorStream
(
true
);
boolean
inheritedIO
=
inheritIO
(
builder
);
boolean
inheritedIO
=
inheritIO
(
builder
);
...
...
spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/AbstractRunMojo.java
View file @
28ed59ca
...
@@ -88,8 +88,9 @@ public abstract class AbstractRunMojo extends AbstractDependencyFilterMojo {
...
@@ -88,8 +88,9 @@ public abstract class AbstractRunMojo extends AbstractDependencyFilterMojo {
private
Boolean
noverify
;
private
Boolean
noverify
;
/**
/**
* The working directory of the application. If specified by default the process
* Current working directory to use for the application. If not specified, basedir
* will be started by forking a new JVM.
* will be used NOTE: the use of working directory means that processes will be
* started by forking a new JVM.
* @since 1.5
* @since 1.5
*/
*/
@Parameter
(
property
=
"run.workingDirectory"
)
@Parameter
(
property
=
"run.workingDirectory"
)
...
...
spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/RunMojo.java
View file @
28ed59ca
...
@@ -16,8 +16,8 @@
...
@@ -16,8 +16,8 @@
package
org
.
springframework
.
boot
.
maven
;
package
org
.
springframework
.
boot
.
maven
;
import
java.net.URL
;
import
java.io.File
;
import
java.io.File
;
import
java.net.URL
;
import
java.net.URLClassLoader
;
import
java.net.URLClassLoader
;
import
java.util.List
;
import
java.util.List
;
...
...
spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/StartMojo.java
View file @
28ed59ca
/*
/*
* Copyright 2012-201
5
the original author or authors.
* Copyright 2012-201
6
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -90,7 +90,7 @@ public class StartMojo extends AbstractRunMojo {
...
@@ -90,7 +90,7 @@ public class StartMojo extends AbstractRunMojo {
@Override
@Override
protected
void
runWithForkedJvm
(
File
workingDirectory
,
List
<
String
>
args
)
protected
void
runWithForkedJvm
(
File
workingDirectory
,
List
<
String
>
args
)
throws
MojoExecutionException
,
MojoFailureException
{
throws
MojoExecutionException
,
MojoFailureException
{
RunProcess
runProcess
=
runProcess
(
args
,
workingDirectory
);
RunProcess
runProcess
=
runProcess
(
workingDirectory
,
args
);
try
{
try
{
waitForSpringApplication
();
waitForSpringApplication
();
}
}
...
@@ -104,9 +104,11 @@ public class StartMojo extends AbstractRunMojo {
...
@@ -104,9 +104,11 @@ public class StartMojo extends AbstractRunMojo {
}
}
}
}
private
RunProcess
runProcess
(
List
<
String
>
args
,
File
workingDirectory
)
throws
MojoExecutionException
{
private
RunProcess
runProcess
(
File
workingDirectory
,
List
<
String
>
args
)
throws
MojoExecutionException
{
try
{
try
{
RunProcess
runProcess
=
new
RunProcess
(
workingDirectory
,
new
JavaExecutable
().
toString
());
RunProcess
runProcess
=
new
RunProcess
(
workingDirectory
,
new
JavaExecutable
().
toString
());
runProcess
.
run
(
false
,
args
.
toArray
(
new
String
[
args
.
size
()]));
runProcess
.
run
(
false
,
args
.
toArray
(
new
String
[
args
.
size
()]));
return
runProcess
;
return
runProcess
;
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment