2016年12月18日 星期日

建立 xcode 新專案出現錯誤訊息

建立 xcode 新專案時,出現錯誤訊息:

Couldn’t communicate with a helper application.
Try your operation again. If that fails, quit and relaunch the application and try again.


解決方法:
在Terminal(終端機)畫面上輸入下列二行程式即可

xcrun git config --global user.email your@email.com
xcrun git config --global user.name your name 
 

安裝 CocoaPods

1.打開Terminal(終端機),輸入以下的的指令:
   $ sudo gem install cocoapods
2. 用Xcode新增一個專案
3. 在Terminal(終端機),cd 至專案目錄,輸入以下的指令
   $ pod init 
4. 再輸入
   $ pod install
5. 以上指令跑完後,會新增一個檔案 .xcworkspace
6. 開啟 .xcworkspace 的檔案,即可作業

2016年12月14日 星期三

清空 MAC 垃圾桶裡的垃圾

有時候點選垃圾桶按清空,裡頭的文件會因為某些原因而無法刪除,

此時打開工具程式 -> 找到終端機 輸入下面的指令:

$ cd ~
$ rm -fr .Trash
$ exit

就會強制的把垃圾桶裡的東西全部刪除。

最後記得要加上 exit 離開,不然任何東西丟到垃圾桶都會徹底刪除。