Module: Avm::Git::SubrepoCheck::ShowResult

Defined in:
lib/avm/git/subrepo_check/show_result.rb

Instance Method Summary collapse

Instance Method Details

#out_attr(key, value) ⇒ Object



26
27
28
# File 'lib/avm/git/subrepo_check/show_result.rb', line 26

def out_attr(key, value)
  out("|#{"#{key}=".white}#{value}")
end

#run_fix_parentObject



17
18
19
20
21
22
23
24
# File 'lib/avm/git/subrepo_check/show_result.rb', line 17

def run_fix_parent
  return unless fix_parent?
  return unless parent_result.error?

  out('|Fixing...'.white)
  self.parent_hash = expected_parent_hash
  out_attr('new parent', parent_result.label)
end

#show_resultObject



9
10
11
12
13
14
15
# File 'lib/avm/git/subrepo_check/show_result.rb', line 9

def show_result
  out(subrepo.subpath.to_path.cyan)
  out_attr('parent', parent_result.label)
  run_fix_parent
  out_attr('remote', remote_result.label)
  out("\n")
end