dfed / swift-shell

A simple wrapper for executing shell commands from Swift

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

swift-shell

A simple wrapper for executing shell commands from Swift

Requirements

  • Swift 5.6
  • Xcode 13.3+

Usage

import SwiftShell

// Getting output from a shell command:
let output = try Process.execute(#"echo "Hello, world!""#)

// Getting output from a shell command within a specific directory:
let output = try Process.execute("ls", within: .path("~/"))

About

A simple wrapper for executing shell commands from Swift

License:Apache License 2.0


Languages

Language:Swift 100.0%