Skip to content

TSCBasic: remove signalled from ProcessResult on Windows #106

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 10, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions Sources/TSCBasic/Process.swift
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,10 @@ public struct ProcessResult: CustomStringConvertible {
public enum ExitStatus: Equatable {
/// The process was terminated normally with a exit code.
case terminated(code: Int32)

#if !os(Windows)
/// The process was terminated due to a signal.
case signalled(signal: Int32)
#endif
}

/// The arguments with which the process was launched.
Expand Down Expand Up @@ -758,9 +759,10 @@ extension ProcessResult.Error: CustomStringConvertible {
switch result.exitStatus {
case .terminated(let code):
stream <<< "terminated(\(code)): "

#if !os(Windows)
case .signalled(let signal):
stream <<< "signalled(\(signal)): "
#endif
}

// Strip sandbox information from arguments to keep things pretty.
Expand Down