在GIT中的Fastlane Appfile?如何检索当前的apple_id?

7
我为我的XCode项目设置了Fastlane进行构建自动化。至少Fastfile(包含构建选项)应该在GIT中,但我也很高兴将Appfile(团队标识符)放入GIT中。主要问题是:Appfile应包含我的apple id。示例:
apple_id "myid@gmail.com" # Your Apple email address

# Default team ID
team_id "AUE7D4LRRX"

for_platform :ios do
 for_lane :production do
    team_id '-' #reset team id
  end
end

是否有办法从苹果/ Xcode 首选项动态获取 Apple ID?在当前的解决方案中,我无法将此 Appfile 添加到GIT,因为每个开发人员都会有自己的版本,而且肯定会有不同的 Apple ID!

谢谢并致以最好的问候!


也许可以从环境变量中获取它? - David Neiss
1个回答

9
你可以轻松地通过环境变量设置Apple ID。 Appfile
apple_id ENV["APPLE_ID"]

...

然后使用以下命令运行 fastlane:

APPLE_ID="email@email.com" fastlane beta

或类似的东西。

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接