Skip to content

Commit

Permalink
#110 Support MacOS (#111)
Browse files Browse the repository at this point in the history
  • Loading branch information
frimtec authored Nov 23, 2022
1 parent 7cf2468 commit 57c3e23
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ API to easily execute PowerShell commands and scripts from Java.
## Supported platforms
* Windows
* Linux (with installed PowerShell)
* MacOS (with installed PowerShell)

## Example
Call PowerShell commands or scripts like this:
Expand All @@ -38,7 +39,7 @@ System.out.println(" output = " + output);
```

## Add dependency
To use jpse in your project you can add the dependecy from [maven central][maven-central] to your software project management tool:
To use jpse in your project you can add the dependency from [maven central][maven-central] to your software project management tool:

In Maven just add the following dependency to your pom.xml:
```xml
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ static PowerShellExecutor instance(Path tempPath) {
String osName = System.getProperty("os.name").toLowerCase();
if (osName.startsWith("win")) {
return new WindowsPowerShellExecutor(tempPath);
} else if (osName.contains("nix") || osName.contains("nux")) {
} else if (osName.contains("nix") || osName.contains("nux") || osName.contains("mac")) {
return new LinuxPowerShellExecutor(tempPath);
} else {
return new UnsupportedOsPowerShellExecutor(osName);
Expand Down

0 comments on commit 57c3e23

Please sign in to comment.