首页 > 编程语言 > 详细

swift笔记三 使用xcode

时间:2015-10-10 21:43:26      阅读:224      评论:0      收藏:0      [点我收藏+]

建一个xcode工程。。OS X > Application > Command Line Tool因为我们只是想玩玩swift语言特性不做UI.

product name; example
org name: cyper 
org id: me.cyper
bundle id: me.cyper.example

保存在桌面.  
example > example.xcodeproj
example > example/main.swift
 

选择products>example,右边identity and type, type选择Unix-Executable可以看到生成的可执行文件的全路径
/Users/cyper/Library/Developer/Xcode/DerivedData/example-ajcwintjwwixdreqjjijwrzqriom/Build/Products/Debug/example

这个hello world文件大约5M

?  Debug  $ pwd
/Users/cyper/Library/Developer/Xcode/DerivedData/example-ajcwintjwwixdreqjjijwrzqriom/Build/Products/Debug
?  Debug  $ ll
total 10904
-rwxr-xr-x  1 cyper  staff   5.3M Oct 10 20:03 example
drwxr-xr-x  4 cyper  staff   136B Oct 10 20:00 example.swiftmodule/
?  Debug  $ ./example
Hello, World!
?  Debug  $





swift笔记三 使用xcode

原文:http://my.oschina.net/uniquejava/blog/515396

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!