Class: Brut::CLI::Apps::DeployBase::GitChecks

Inherits:
Object
  • Object
show all
Defined in:
lib/brut/cli/apps/deploy_base.rb

Instance Method Summary collapse

Constructor Details

#initialize(out:, err:, executor:, warn_only: false) ⇒ GitChecks

Returns a new instance of GitChecks.



9
10
11
12
13
14
# File 'lib/brut/cli/apps/deploy_base.rb', line 9

def initialize(out:, err:, executor:, warn_only: false)
  @out       = out
  @err       = err
  @executor  = executor
  @warn_only = warn_only
end

Instance Method Details

#check!Object



16
17
18
19
20
# File 'lib/brut/cli/apps/deploy_base.rb', line 16

def check!
  require_main_branch!
  require_no_local_changes!
  require_pushed_to_main!
end