美文网首页ios
fastlane基本使用记录

fastlane基本使用记录

作者: 黎峰麟 | 来源:发表于2019-01-04 10:35 被阅读6次

官方文档 https://docs.fastlane.tools/getting-started/ios/setup/
参考文章 https://www.jianshu.com/p/5d836e89d9d1

1 安装Installing fastlane

     xcode-select --install
    # Using RubyGems
    sudo gem install fastlane -NV

    # Alternatively using Homebrew
    brew cask install fastlane

2 设置 Setting up fastlane

   进入项目文件夹
   fastlane init

3 截屏


1.  Create a new UI Test target in your Xcode project (See the top part of [this article]
      (https://krausefx.com/blog/run-xcode-7-ui-tests-from-the-command-line))
2.  Run `fastlane snapshot init` in your project folder
3.  Add the `./SnapshotHelper.swift` file to your UI Test target (You can move the 
      file anywhere you want)
4.  Add a new Xcode scheme for the newly created UI Test target
5.  Edit the scheme
6.  In the list on the left click "Build", and enable the checkbox under the 
     "Run" column for your target. 
7.  Enable the `Shared` box of the newly created scheme
8.  (Objective C only) Add the bridging header to your test class.
    *   `#import "MYUITests-Swift.h"`
    *   The bridging header is named after your test target with -Swift.h appended.
9.  In your UI Test class, click the `Record` button on the bottom left and record 
      your interaction
10.  To take a screenshot, call the following between interactions
    *   Objective C: `[Snapshot snapshot:@"01LoginScreen" timeWaitingForIdle:10];`
11.  Add the following code to your `setUp()` method:

      XCUIApplication *app = [[XCUIApplication alloc] init];
      [Snapshot setupSnapshot:app];
      [app launch];

12. In the terminal run fastlane snapshot.

4上传蒲公英和App Store 官方文档 https://www.pgyer.com/doc/view/fastlane

 之后执行动作打包 
 fastlane beta 或者 fastlane release    (蒲公英和App Store)
 等待就可以了中途不要中断和移动ipa位置

5 截屏组件的安装
sudo gem install snapshot
出现一个错误

  You don't have write permissions for the /usr/bin directory.
  解决方案
  sudo gem install snapshot -n /usr/local/bin
企业微信截图_e5cbdf94-9a0e-46ce-9d4b-4c2920121c19.png

蒲公英上传结束(可正常使用)


企业微信截图_1f47cb42-403d-49a1-b871-fc058263ec79.png

App Store 上传结束(就到了这一步但是却看不到二进制文件不知是什么原因-少加了一个权限)


企业微信截图_d3a32050-7298-4f6b-a898-8585850012cf.png

相关文章

  • fastlane基本使用记录

    官方文档 https://docs.fastlane.tools/getting-started/ios/set...

  • iOS 自动打包 - fastlane (一)

    1 本文只是fastlane的基本使用.fastlane (二)有更多讲解2 使用fastlane前,确保你已经可...

  • FastLane基本使用

    1、安装 sudo gem install -n /usr/local/bin fastlane 要求ruby为最...

  • Fastlane 使用记录

    安装 fastlane的快速上手文档:https://docs.fastlane.tools/这篇文章也不错使用b...

  • fastlane 使用记录

    安装以及初始化 安装以及初始化这里注意Xcode 命令行工具现在通过命令行无法下载,可通过官网下载 相关配置 更新...

  • Fastlane 问题记录

    fastlane安装使用使用的教程很多,套路基本固定。此处仅记录耗费了自己几天时间的坑,以便后续方便查阅。有个感悟...

  • fastlane snapshot 使用记录

    前面省去 fastlane 的安转过程。 1、在工程目录文件下面执行 fastlane init2、执行 snap...

  • fastlane

    安装 fastlane fastlane tools 使用说明brew cask install fastlane...

  • fastlane iOS官方翻译一 (初始化设置)

    开始使用fastlane配置fastlane 安装fastlane 安装最新版本的Xcode 安装fastlane...

  • fastlane感悟

    fastlane感悟 目标:使用fastlane自动打包上传appStore 一、 安装fastlane fast...

网友评论

    本文标题:fastlane基本使用记录

    本文链接:https://www.haomeiwen.com/subject/cdchrqtx.html