Class: Kaya::Base

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

Instance Method Summary collapse

Instance Method Details

#byeObject



170
171
172
173
174
# File 'lib/kaya.rb', line 170

def bye
  if yes? "Are you sure to say bye to Kaya? (yes/no)"
    Kaya::Commands.bye
  end
end

#helpObject



123
124
125
# File 'lib/kaya.rb', line 123

def help
  Kaya::Commands.help
end

#installObject



128
129
130
# File 'lib/kaya.rb', line 128

def install
  Kaya::Commands.install
end

#resetObject



158
159
160
161
162
# File 'lib/kaya.rb', line 158

def reset
  if yes? "Are you sure to reset all register? (yes/no)"
    Kaya::Commands.reset
  end
end

#reset_suitesObject



165
166
167
# File 'lib/kaya.rb', line 165

def reset_suites
  Kaya::Commands.reset_suites
end

#restartObject



153
154
155
# File 'lib/kaya.rb', line 153

def restart
  Kaya::Commands.restart
end

#startObject



134
135
136
137
138
139
140
141
142
143
144
145
# File 'lib/kaya.rb', line 134

def start
  if Dir.exist? "#{Dir.pwd}/kaya"
    $K_LOG = Logger.new("#{Dir.pwd}/kaya/kaya_log",1,1024*1024)
    Kaya::Commands.start(options["nodemon"])
  else
    puts "

Could not find kaya folder on root project folder. You can use `kaya install`

".red
  end
end

#stopObject



148
149
150
# File 'lib/kaya.rb', line 148

def stop
  Kaya::Commands.stop
end