@@ -72,14 +72,14 @@ private Command generateCommandLine(Path nativeFolder) throws IOException {
7272 if (OperatingSystem .CURRENT_OS == OperatingSystem .WINDOWS ) {
7373 // res.add("cmd", "/C", "start", "unused title", "/B", "/high");
7474 } else if (OperatingSystem .CURRENT_OS .isLinuxOrBSD () || OperatingSystem .CURRENT_OS == OperatingSystem .MACOS ) {
75- res .add ("nice" , "-n" , "-5" );
75+ res .addAll ("nice" , "-n" , "-5" );
7676 }
7777 break ;
7878 case ABOVE_NORMAL :
7979 if (OperatingSystem .CURRENT_OS == OperatingSystem .WINDOWS ) {
8080 // res.add("cmd", "/C", "start", "unused title", "/B", "/abovenormal");
8181 } else if (OperatingSystem .CURRENT_OS .isLinuxOrBSD () || OperatingSystem .CURRENT_OS == OperatingSystem .MACOS ) {
82- res .add ("nice" , "-n" , "-1" );
82+ res .addAll ("nice" , "-n" , "-1" );
8383 }
8484 break ;
8585 case NORMAL :
@@ -89,14 +89,14 @@ private Command generateCommandLine(Path nativeFolder) throws IOException {
8989 if (OperatingSystem .CURRENT_OS == OperatingSystem .WINDOWS ) {
9090 // res.add("cmd", "/C", "start", "unused title", "/B", "/belownormal");
9191 } else if (OperatingSystem .CURRENT_OS .isLinuxOrBSD () || OperatingSystem .CURRENT_OS == OperatingSystem .MACOS ) {
92- res .add ("nice" , "-n" , "1" );
92+ res .addAll ("nice" , "-n" , "1" );
9393 }
9494 break ;
9595 case LOW :
9696 if (OperatingSystem .CURRENT_OS == OperatingSystem .WINDOWS ) {
9797 // res.add("cmd", "/C", "start", "unused title", "/B", "/low");
9898 } else if (OperatingSystem .CURRENT_OS .isLinuxOrBSD () || OperatingSystem .CURRENT_OS == OperatingSystem .MACOS ) {
99- res .add ("nice" , "-n" , "5" );
99+ res .addAll ("nice" , "-n" , "5" );
100100 }
101101 break ;
102102 }
@@ -179,7 +179,7 @@ private Command generateCommandLine(Path nativeFolder) throws IOException {
179179
180180 if (addProxyOptions ) {
181181 if (options .getProxyOption () == null || options .getProxyOption () == ProxyOption .Default .INSTANCE ) {
182- res .add ("-Djava.net.useSystemProxies=" , " true" );
182+ res .add ("-Djava.net.useSystemProxies=true" );
183183 } else if (options .getProxyOption () instanceof ProxyOption .Http httpProxy ) {
184184 res .add ("-Dhttp.proxyHost=" + httpProxy .host ());
185185 res .add ("-Dhttp.proxyPort=" + httpProxy .port ());
@@ -737,7 +737,7 @@ else if (!isWindows && !(scriptExtension.equals("sh") || scriptExtension.equals(
737737 writer .newLine ();
738738 }
739739 writer .newLine ();
740- writer .write (new CommandBuilder ().add ("cd" , "/D" , FileUtils .getAbsolutePath (repository .getRunDirectory (version .getId ()))).toString ());
740+ writer .write (new CommandBuilder ().addAll ("cd" , "/D" , FileUtils .getAbsolutePath (repository .getRunDirectory (version .getId ()))).toString ());
741741 } else {
742742 writer .write ("#!/usr/bin/env bash" );
743743 writer .newLine ();
@@ -746,10 +746,10 @@ else if (!isWindows && !(scriptExtension.equals("sh") || scriptExtension.equals(
746746 writer .newLine ();
747747 }
748748 if (commandLine .tempNativeFolder != null ) {
749- writer .write (new CommandBuilder ().add ("ln" , "-s" , FileUtils .getAbsolutePath (nativeFolder ), commandLine .tempNativeFolder .toString ()).toString ());
749+ writer .write (new CommandBuilder ().addAll ("ln" , "-s" , FileUtils .getAbsolutePath (nativeFolder ), commandLine .tempNativeFolder .toString ()).toString ());
750750 writer .newLine ();
751751 }
752- writer .write (new CommandBuilder ().add ("cd" , FileUtils .getAbsolutePath (repository .getRunDirectory (version .getId ()))).toString ());
752+ writer .write (new CommandBuilder ().addAll ("cd" , FileUtils .getAbsolutePath (repository .getRunDirectory (version .getId ()))).toString ());
753753 }
754754 writer .newLine ();
755755 if (StringUtils .isNotBlank (options .getPreLaunchCommand ())) {
@@ -769,7 +769,7 @@ else if (!isWindows && !(scriptExtension.equals("sh") || scriptExtension.equals(
769769 writer .newLine ();
770770 }
771771 if (commandLine .tempNativeFolder != null ) {
772- writer .write (new CommandBuilder ().add ("rm" , commandLine .tempNativeFolder .toString ()).toString ());
772+ writer .write (new CommandBuilder ().addAll ("rm" , commandLine .tempNativeFolder .toString ()).toString ());
773773 writer .newLine ();
774774 }
775775 }
0 commit comments