Module: Dip

Defined in:
lib/dip.rb,
lib/dip/cli.rb,
lib/dip/config.rb,
lib/dip/errors.rb,
lib/dip/cli/dns.rb,
lib/dip/cli/ssh.rb,
lib/dip/command.rb,
lib/dip/version.rb,
lib/dip/cli/base.rb,
lib/dip/run_vars.rb,
lib/dip/cli/nginx.rb,
lib/dip/cli/console.rb,
lib/dip/environment.rb,
lib/dip/commands/dns.rb,
lib/dip/commands/run.rb,
lib/dip/commands/ssh.rb,
lib/dip/commands/list.rb,
lib/dip/commands/nginx.rb,
lib/dip/commands/compose.rb,
lib/dip/commands/console.rb,
lib/dip/interaction_tree.rb,
lib/dip/commands/provision.rb

Defined Under Namespace

Modules: Commands Classes: CLI, Command, Config, Environment, InteractionTree, RunVars, VersionMismatchError

Constant Summary collapse

Error =
Class.new(StandardError)
VERSION =
"7.3.1"

Class Method Summary collapse

Class Method Details

.bin_pathObject


17
18
19
# File 'lib/dip.rb', line 17

def bin_path
  $PROGRAM_NAME.start_with?("./") ? File.expand_path($PROGRAM_NAME) : "dip"
end

.configObject


9
10
11
# File 'lib/dip.rb', line 9

def config
  @config ||= Dip::Config.new
end

.envObject


13
14
15
# File 'lib/dip.rb', line 13

def env
  @env ||= Dip::Environment.new(config.exist? ? config.environment : {})
end

.reset!Object


27
28
29
30
# File 'lib/dip.rb', line 27

def reset!
  @config = nil
  @env = nil
end