Class: Terrestrial::Cli::Push

Inherits:
Command
  • Object
show all
Defined in:
lib/terrestrial/cli/push.rb

Instance Method Summary collapse

Methods inherited from Command

#initialize, run

Constructor Details

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

Instance Method Details

#runObject



5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# File 'lib/terrestrial/cli/push.rb', line 5

def run
  Config.load!
  MixpanelClient.track("cli-push-command")
  load_string_registry

  if string_registry.entries.any?
    if duplicates.any?
      show_duplicate_error_message
    else
      do_push
    end
  else
    show_no_entries_error_message
  end
end