Class: PebbleX::CLI

Inherits:
Thor
  • Object
show all
Defined in:
lib/pebble_x/cli.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.exit_on_failure?Boolean

Returns:

  • (Boolean)


12
13
14
# File 'lib/pebble_x/cli.rb', line 12

def self.exit_on_failure?
  true
end

Instance Method Details

#buildObject



29
30
31
32
# File 'lib/pebble_x/cli.rb', line 29

def build
  pebble = command_helper PebbleX::Pebble
  exit(pebble.build)
end

#debugObject



37
38
39
40
41
42
# File 'lib/pebble_x/cli.rb', line 37

def debug
  pebble = command_helper PebbleX::Pebble
  pebble.phone = options[:phone] if options[:phone]
  pebble.pebble_id = options[:pebble_id] if options[:pebble_id]
  exit(pebble.debug)
end

#versionObject



17
18
19
# File 'lib/pebble_x/cli.rb', line 17

def version
  puts PebbleX::VERSION
end

#xcodeObject



23
24
25
26
# File 'lib/pebble_x/cli.rb', line 23

def xcode
  xcode = command_helper PebbleX::Xcode
  xcode.create_project
end