Command-line arguments for the current process.
SDK
- Xcode 8.0+
Framework
- Swift Standard Library
Command-line arguments for the current process.
SDK
Framework
static var arguments: [String]
Access to the swift arguments, also use lazy initialization of static properties to safely initialize the swift arguments.
static var argc: Int32
Access to the raw argc value from C.
static var unsafe Argv: Unsafe Mutable Pointer<Unsafe Mutable Pointer<Int8>?>
Access to the raw argv value from C. Accessing the argument vector through this pointer is unsafe.
func read Line(stripping Newline: Bool) -> String?
Returns a string read from standard input through the end of the current line or until EOF is reached.