Module: Warbler::Runtime

Defined in:
lib/warbler/runtime.rb

Overview

Extension module for a Bundler::Runtime instance, to add methods to create a Bundler environment file specific to war packaging.

Defined Under Namespace

Classes: Spec

Constant Summary collapse

WAR_ENV =
".bundle/war-environment.rb"

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#gem_pathObject



8
9
10
# File 'lib/warbler/runtime.rb', line 8

def gem_path
  @gem_path || Config::DEFAULT_GEM_PATH
end

Instance Method Details

#rb_lock_fileObject

deprecated; compatibility with Bundler <= 0.9.14



28
29
30
# File 'lib/warbler/runtime.rb', line 28

def rb_lock_file            #:nocov:
  root.join(WAR_ENV)        #:nocov:
end

#specs_for_lock_fileObject

:nocov:



32
33
34
# File 'lib/warbler/runtime.rb', line 32

def specs_for_lock_file
  super.map {|s| Spec.new(s, gem_path)}
end

#war_specsObject



40
41
42
# File 'lib/warbler/runtime.rb', line 40

def war_specs
  respond_to?(:requested_specs) ? requested_specs : specs_for
end

#write_war_environmentObject



36
37
38
# File 'lib/warbler/runtime.rb', line 36

def write_war_environment
  write_rb_lock
end