Top Level Namespace

Defined Under Namespace

Modules: InlineFormsInstaller Classes: ExampleAppApartmentFieldTurboTest, ExampleAppApartmentNameListTest, ExampleAppApartmentNameRequiredTest, ExampleAppApartmentNameValidationTest, ExampleAppApartmentOpeningDateTest, ExampleAppApartmentPhotoTest, ExampleAppApartmentPhotosPaginationTest, ExampleAppApartmentRowTurboTest, ExampleAppApartmentTopLevelNewTest, ExampleAppApartmentTopLevelPaginationTest, ExampleAppApartmentVersionsTurboTest, ExampleAppGuestAccessTest, ExampleAppIntegrationTestCase, ExampleAppOwnerTabsTest, ExampleAppPaperTrailChangesetTest, ExampleAppPhotoRevertTest, ExampleAppPhotosTest, ExampleAppPlainTextRichTextEdgeCasesTest, ExampleAppRoutingTest, ExampleAppTurboLayoutTest, ExampleAppValidationHintsTest

Constant Summary collapse

INSTALLER_ROOT =
File.expand_path(ENV.fetch("INLINE_FORMS_INSTALLER_ROOT", File.expand_path("..", __dir__)))
INLINE_FORMS_ROOT =
File.expand_path(ENV.fetch("INLINE_FORMS_ROOT", INSTALLER_ROOT))

Instance Method Summary collapse

Instance Method Details

#bundle_install!Object



24
25
26
27
28
29
30
31
32
# File 'lib/inline_forms_installer/installer_core.rb', line 24

def bundle_install!
  say "- Running bundle install..."
  unless system("bundle", "install")
    abort "ERROR: bundle install failed in #{Dir.pwd}. From the app directory run: rvm use . && bundle install"
  end
  unless system("bundle", "check")
    abort "ERROR: bundle check failed (gems missing). From the app directory run: rvm use . && bundle install"
  end
end

#use_app_rvm_gemset!Object



7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# File 'lib/inline_forms_installer/installer_core.rb', line 7

def use_app_rvm_gemset!
  return if ENV["skiprvm"] == "true"
  return unless (gemset = ENV["inline_forms_rvm_gemset"]).to_s != ""

  begin
    require "rvm"
  rescue LoadError
    say "rvm gem not available; skipping gemset switch", :yellow
    return
  end
  return unless RVM.current

  say "Working directory is #{Dir.pwd}", :green
  RVM.use_from_path! "."
  say "Installing using gemset: #{RVM.current.environment_name}", :green
end