Skip to content

Commit fdffb2d

Browse files
Federico Fissorecmaglie
Federico Fissore
authored andcommitted
Setting CYGWIN=nodosfilewarning env variable on windows
1 parent 44a6cbf commit fdffb2d

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

app/src/processing/app/helpers/ProcessUtils.java

+8-3
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
package processing.app.helpers;
22

3-
import java.io.IOException;
4-
53
import processing.app.Base;
64

5+
import java.io.IOException;
6+
import java.util.Map;
7+
78
public class ProcessUtils {
89

910
public static Process exec(String[] command) throws IOException {
@@ -20,6 +21,10 @@ public static Process exec(String[] command) throws IOException {
2021
String[] cmdLine = new String[command.length];
2122
for (int i = 0; i < command.length; i++)
2223
cmdLine[i] = command[i].replace("\"", "\\\"");
23-
return Runtime.getRuntime().exec(cmdLine);
24+
25+
ProcessBuilder pb = new ProcessBuilder(cmdLine);
26+
Map<String, String> env = pb.environment();
27+
env.put("CYGWIN", "nodosfilewarning");
28+
return pb.start();
2429
}
2530
}

0 commit comments

Comments
 (0)