Module: BitScopeAdd

Included in:
Takelage::BitScope
Defined in:
lib/takelage/bit/scope/add.rb

Overview

takelage bit scope add

Instance Method Summary collapse

Instance Method Details

#bit_scope_add(scope) ⇒ Object

Backend method for bit scope add.



6
7
8
9
10
11
12
13
14
15
16
17
18
# File 'lib/takelage/bit/scope/add.rb', line 6

def bit_scope_add(scope)
  log.debug "Adding bit remote scope \"#{scope}\" to local workspace"

  return false unless configured? %w[bit_ssh bit_remote]

  return false unless _bit_scope_add_workspace_ready?

  return false unless _bit_scope_add_scope_exists? scope

  run _bit_scope_add_cmd scope

  log.info "Added bit remote scope \"#{scope}\" to local bit workspace"
end