mas/MasKit/ExternalCommands/OpenCommand.swift
Ben Chatelain dbf20d6d7a 🚧 Add OpenCommand
2019-01-03 15:15:53 -08:00

27 lines
626 B
Swift

//
// OpenCommand.swift
// MasKit
//
// Created by Ben Chatelain on 1/2/19.
// Copyright © 2019 mas-cli. All rights reserved.
//
/// Wrapper for the external open system command.
/// https://ss64.com/osx/open.html
public struct OpenCommand: ExternalCommand {
public var binaryPath: String
public var arguments: [String]
public let process = Process()
public let stdoutPipe = Pipe()
public let stderrPipe = Pipe()
public init(
binaryPath: String = "/usr/bin/open",
arguments: [String] = []
) {
self.binaryPath = binaryPath
self.arguments = arguments
}
}