ios – FastLanes.在Xcode项目根文件夹中运行sh动作

ios – FastLanes.在Xcode项目根文件夹中运行sh动作,第1张

概述在以下Fastfile上运行fastlane build_and_rename, lane :build_and_rename do sigh gym(output_directory: "./Build/") sh "mv ./Build/MY-APP.ipa ./Build/nicely_name.ipa" end 导致以下错误:./Build/MY-APP.ipa 在以下Fastfile上运行fastlane build_and_rename,

lane :build_and_rename do    sigh    gym(output_directory: "./Build/")    sh "mv ./Build/MY-APP.ipa ./Build/nicely_name.ipa"  end

导致以下错误:./Build/MY-APP.ipa:没有这样的文件或目录.

测试显示FastLane的sh动作在./fastlane目录中运行.示例,fastlane test_sh用于以下Fastfile

lane :test_sh do    sh "touch where_am_i.txt"  end

导致在./fastlane文件夹中创建where_am_i.txt.不在运行fastlane的文件夹中.

显然我可以更改所有脚本以包含../但是想知道是否有办法在xCode的根项目中使用fastlane run sh动作?

解决方法 事实证明这很简单,只需添加cd ..&&要更改到根目录.

lane :test_sh do    sh "cd .. && touch where_am_i.txt"end

https://github.com/fastlane/fastlane/issues/990#issuecomment

总结

以上是内存溢出为你收集整理的ios – FastLanes.在Xcode项目根文件夹中运行sh动作全部内容,希望文章能够帮你解决ios – FastLanes.在Xcode项目根文件夹中运行sh动作所遇到的程序开发问题。

如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。

欢迎分享,转载请注明来源:内存溢出

原文地址:https://54852.com/web/1062058.html

(0)
打赏 微信扫一扫微信扫一扫 支付宝扫一扫支付宝扫一扫
上一篇 2022-05-25
下一篇2022-05-25

发表评论

登录后才能评论

评论列表(0条)

    保存