Class: Mistilteinn::Cli::IsInside

Inherits:
Command
  • Object
show all
Defined in:
lib/mistilteinn/cli/is_inside.rb

Instance Attribute Summary

Attributes inherited from Command

#args, #config, #its

Instance Method Summary collapse

Methods inherited from Command

commands, desc, inherited, #initialize, name, #run

Constructor Details

This class inherits a constructor from Mistilteinn::Cli::Command

Instance Method Details

#actionObject



9
10
11
12
13
14
15
# File 'lib/mistilteinn/cli/is_inside.rb', line 9

def action
  if ::Mistilteinn::Git::work_tree? and config.exist? then
    exit 0
  else
    exit 1
  end
end