Skip to content

Commit

Permalink
Fix Process.findExecutable
Browse files Browse the repository at this point in the history
  • Loading branch information
stevapple committed Apr 22, 2022
1 parent ec7e1bf commit 947f56f
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Sources/TSCBasic/Process.swift
Original file line number Diff line number Diff line change
Expand Up @@ -463,6 +463,13 @@ public final class Process {
if localFileSystem.isExecutableFile(abs) {
return abs
}
#if os(Windows)
if abs.extension != "exe" && abs.extension != "",
case let abs = abs.parentDirectory.appending(component: abs.basename + executableFileSuffix),
localFileSystem.isExecutableFile(abs) {
return abs
}
#endif
}
return nil
}
Expand Down

0 comments on commit 947f56f

Please sign in to comment.