Class: DPL::Provider::Biicode

Inherits:
DPL::Provider show all
Defined in:
lib/dpl/provider/biicode.rb

Instance Attribute Summary

Attributes inherited from DPL::Provider

#context, #options

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from DPL::Provider

apt_get, #cleanup, #commit_msg, context, #create_key, #deploy, #detect_encoding?, #encoding_for, #error, experimental, #initialize, #log, new, npm_g, #option, pip, requires, #run, #setup_git_credentials, #setup_git_ssh, #sha, shell, #uncleanup, #user_agent, #warn

Constructor Details

This class inherits a constructor from DPL::Provider

Class Method Details

.install_biicodeObject



9
10
11
12
13
# File 'lib/dpl/provider/biicode.rb', line 9

def self.install_biicode
  unless find_executable 'bii'
		context.shell "wget http://apt.biicode.com/install.sh -O install_biicode.sh && chmod +x install_biicode.sh && ./install_biicode.sh"
	end
end

Instance Method Details

#check_appObject

Raises:



21
22
23
24
# File 'lib/dpl/provider/biicode.rb', line 21

def check_app
  raise Error, "must supply a username" unless option(:user)
  raise Error, "must supply a password" unless option(:password)
end

#check_authObject



26
27
28
# File 'lib/dpl/provider/biicode.rb', line 26

def check_auth
  context.shell "bii user #{option(:user)} -p #{option(:password)}"
end

#needs_key?Boolean

Returns:

  • (Boolean)


17
18
19
# File 'lib/dpl/provider/biicode.rb', line 17

def needs_key?
  false
end

#push_appObject



30
31
32
# File 'lib/dpl/provider/biicode.rb', line 30

def push_app
  context.shell "bii publish --msg \"Travis publication\""
end