Fastlane 使用筆記

Fastlane 記錄

  1. 打開終端輸入命令git

    xcode-select --install
  2. 查看ruby版本 (必須大於2.0不然進行升級)github

    ruby -v
  3. 安裝fastlanexcode

    sudo gem install fastlane -NV
  4. 查看fastlane版本ruby

    fastlane -v
  5. cd到一個項目進行初始化fastlane插件

    fastlane init
  6. 輸入AppleId和密碼rest

  7. 提示了fastlane不是最新版本code

  8. 添加鏡像ip

    gem sources --add https://rubygems.org
  9. 查看鏡像get

    gem sources
    
    ****************************************
    
    http://rubygems-china.oss.aliyuncs.com
    
    https://rubygems.org
    
    ****************************************
  10. 安裝最新fastlaneit

    sudo gem install fastlane
  11. 安裝fastlane插件

    * fastlane add_plugin pgyer
    * fastlane add_plugin versioning
  12. 查看fastlane支持的插件

    fastlane search_plugins

備註:

  1. fastlane beta 命令 報錯:

    [!] Add 'gem "cocoapods"' to your Gemfile and restart fastlane

    解決方法:

    修改Gemfild 裏面的 gem 'fastlane'  爲 gem "cocoapods"

    此時報錯 method `to_plist' not defined in Array 

    解決辦法,分別執行如下命令: 連接

    rvm @global do gem uninstall fastlane 
    rvm all do gem uninstall fastlane
    gem uninstall fastlane
    gem install fastlane

    從新安裝fastlane以後,執行fastlane beta 能夠看到導出的ipa

  2. 工程爲cocoapods 若出錯能夠修改 

    Fastfile before_all do cocoapods(use_bundle_exec: false)
相關文章
相關標籤/搜索