Skip to content

Commit

Permalink
Issue #232: Linux connector cli not functioning locally
Browse files Browse the repository at this point in the history
fix shell issue
  • Loading branch information
SafaeAJ committed Jun 12, 2024
1 parent 9ac1c6b commit 1cbda0e
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,11 @@ static ProcessBuilder createProcessBuilder(final String command) {
if (LocalOsHandler.isWindows()) {
builder.command(System.getenv("ComSpec"), "/C", command);
} else {
builder.command(System.getenv("SHELL"), "-c", command);
String shell = System.getenv("SHELL");
if (shell == null) {
shell = "/bin/sh";
}
builder.command(shell, "-c", command);
}
return builder;
}
Expand Down

0 comments on commit 1cbda0e

Please sign in to comment.