Class: Everywhere::Commands::Doctor
- Inherits:
-
Dry::CLI::Command
- Object
- Dry::CLI::Command
- Everywhere::Commands::Doctor
- Defined in:
- lib/everywhere/commands/doctor.rb
Overview
Check that this machine can build desktop apps.
Instance Method Summary collapse
Instance Method Details
#call ⇒ Object
12 13 14 15 16 17 18 19 20 21 |
# File 'lib/everywhere/commands/doctor.rb', line 12 def call(**) ok = true ok &= check("rbe-tebako installed") { Shellout.run?("rbe-tebako help > /dev/null 2>&1") } ok &= check("cargo installed") { Shellout.run?("cargo --version > /dev/null 2>&1") } ok &= check("homebrew bison") { !`brew --prefix bison 2>/dev/null`.strip.empty? } puts ok ? UI.success("ready to build") : UI.bad("fix the items above (see https://rubyeverywhere.com/docs/diy/requirements)") exit(1) unless ok end |