美文网首页
iOS开发使用fastlane自动打包配置遇到的问题

iOS开发使用fastlane自动打包配置遇到的问题

作者: jinrui_w | 来源:发表于2020-09-18 15:00 被阅读0次

使用Fastlane自动打包无法登录问题

自动登录要求输入6位验证码,输入验证码后一直无响应

Available session is not valid any more. Continuing with normal login.
Two-factor Authentication (6 digits code) is enabled for account '***@***.com'
More information about Two-factor Authentication: https://support.apple.com/en-us/HT204915
If you're running this in a non-interactive session (e.g. server or CI)
check out https://github.com/fastlane/fastlane/tree/master/spaceship#2-step-verification
(Input `sms` to escape this prompt and select a trusted phone number to send the code as a text message)
(You can also set the environment variable `SPACESHIP_2FA_SMS_DEFAULT_PHONE_NUMBER` to automate this)
(Read more at: https://github.com/fastlane/fastlane/blob/master/spaceship/docs/Authentication.md#auto-select-sms-via-spaceship_2fa_sms_default_phone_number)
Please enter the 6 digit code:

解决办法: 终端执行bundle exec fastlane spaceauth

配置FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD

  • 首先到apple id管理页面生成App专用密码
  • 设置环境变量,这个设置取决于你使用的shell种类,我使用的是zsh,终端执行:vim ~/.zshrc,然后添加EXPORT FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD=上一步生产的专用密码,保存退出,重启终端,可以通过终端执行EXPORT,查看是否添加成功

相关文章

网友评论

      本文标题:iOS开发使用fastlane自动打包配置遇到的问题

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