在当前目录中找不到 fastlane
Posted
技术标签:
【中文标题】在当前目录中找不到 fastlane【英文标题】:Could not find fastlane in current directory 【发布时间】:2019-07-02 21:32:49 【问题描述】:我的 fastlane 文件夹能够运行 fastlane match development 和 fastlane match appstore,但在 circleci 上运行 bundle exec fastlane $FASTLANE ios beta 时收到此错误。我还需要配置什么才能使其正常工作?
这是它产生的输出:-
[12:32:24]: All required keys, certificates and provisioning profiles are installed ????
[⠋] ???? [⠙] ???? [⠹] ???? [⠸] ???? [⠼] ???? [⠴] ???? [⠦] ???? [✔] ????
[12:32:27]: Could not find fastlane in current directory. Make sure to have your fastlane configuration files inside a folder called "fastlane". Would you like to set fastlane up?
Looking for related GitHub issues on fastlane/fastlane...
➡️ Fastlain android screengrab. Could not retrieve response as fastlane runs in non-interactive mode
#14869 [open] 4 ????
2 weeks ago
➡️ FastLane 2.124 FastlaneCore::Interface::FastlaneCrash: [!] Could not retrieve response as fastlane runs in non-interactive mode
#14835 [open] 4 ????
2 weeks ago
➡️ Supply isn't working on CI with Google auth .p12 files
#14128 [closed] 2 ????
20 Apr 2019
and 36 more at: https://github.com/fastlane/fastlane/search?q=Could%20not%20retrieve%20response%20as%20fastlane%20runs%20in%20non-interactive%20mode&type=Issues&utf8=✓
???? You can ⌘ + double-click on links to open them directly in your browser.
bundler: failed to load command: fastlane (/usr/local/bin/fastlane)
FastlaneCore::Interface::FastlaneCrash: [!] Could not retrieve response as fastlane runs in non-interactive mode
/Library/Ruby/Gems/2.3.0/gems/fastlane-2.126.0/fastlane_core/lib/fastlane_core/ui/interface.rb:129:in crash!' /Library/Ruby/Gems/2.3.0/gems/fastlane-2.126.0/fastlane_core/lib/fastlane_core/ui/implementations/shell.rb:155:in verify_interactive!'
/Library/Ruby/Gems/2.3.0/gems/fastlane-2.126.0/fastlane_core/lib/fastlane_core/ui/implementations/shell.rb:133:in confirm' /Library/Ruby/Gems/2.3.0/gems/fastlane-2.126.0/fastlane_core/lib/fastlane_core/ui/ui.rb:17:in method_missing'
/Library/Ruby/Gems/2.3.0/gems/fastlane-2.126.0/fastlane/lib/fastlane/commands_generator.rb:343:in ensure_fastfile' /Library/Ruby/Gems/2.3.0/gems/fastlane-2.126.0/fastlane/lib/fastlane/commands_generator.rb:107:in block (2 levels) in run'
/Library/Ruby/Gems/2.3.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:178:in call' /Library/Ruby/Gems/2.3.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:153:in run'
/Library/Ruby/Gems/2.3.0/gems/commander-fastlane-4.4.6/lib/commander/runner.rb:476:in run_active_command' /Library/Ruby/Gems/2.3.0/gems/fastlane-2.126.0/fastlane_core/lib/fastlane_core/ui/fastlane_runner.rb:76:in run!'
/Library/Ruby/Gems/2.3.0/gems/commander-fastlane-4.4.6/lib/commander/delegates.rb:15:in run!' /Library/Ruby/Gems/2.3.0/gems/fastlane-2.126.0/fastlane/lib/fastlane/commands_generator.rb:333:in run'
/Library/Ruby/Gems/2.3.0/gems/fastlane-2.126.0/fastlane/lib/fastlane/commands_generator.rb:41:in start' /Library/Ruby/Gems/2.3.0/gems/fastlane-2.126.0/fastlane/lib/fastlane/cli_tools_distributor.rb:119:in take_off'
/Library/Ruby/Gems/2.3.0/gems/fastlane-2.126.0/bin/fastlane:23:in <top (required)>' /usr/local/bin/fastlane:22:in load'
/usr/local/bin/fastlane:22:in `<top (required)>'
Exited with code 1
【问题讨论】:
什么是bundle exec fastlane $FASTLANE ios beta
- 为什么在命令中使用$FASTLANE
?你能编辑你的问题以包含你得到的完整输出吗?
【参考方案1】:
您需要添加额外的步骤来检查 fastlane 是否安装正确
bundle check || bundle install --path vendor/bundle
如果您使用的是 CircleCI 2.0,则需要执行以下步骤
jobs:
...
setupFastLane:
executor:
name: default
steps:
- checkout
- run:
name: Select Ruby Version
command: echo "ruby-2.4" > .ruby-version
- restore_cache:
keys:
- m2-gems- checksum "Gemfile.lock"
- m2-gems-
- run:
name: Install Ruby Gems
command: bundle check || bundle install --path vendor/bundle
environment:
BUNDLE_JOBS: 4
BUNDLE_RETRY: 3
- save_cache:
key: m2-gems- checksum "Gemfile.lock"
paths:
- vendor/bundle
【讨论】:
以上是关于在当前目录中找不到 fastlane的主要内容,如果未能解决你的问题,请参考以下文章
在当前目录中找不到 Procfile 和 package.json 文件 - 请参阅 run-foreman.js
使用 fastlane 在 crashlytics 包中找不到提交二进制文件