Last active
August 29, 2015 14:02
-
-
Save correia/2076f6c427697e1df8b3 to your computer and use it in GitHub Desktop.
A verbose alternative to NSProcessInfo.processInfo().arguments
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// command-line-args.swift | |
// | |
// Created by Jim Correia on 6/4/14. | |
// Copyright (c) 2014-2015 Jim Correia. All rights reserved. | |
// | |
print("PROG_NAME = \(Process.arguments[0])") | |
print("ARGC = \(Process.argc)") | |
print("ARGV = \(Process.arguments)") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Updated for Swift 2 on 2015/06/10