Class: Makit::LegacyCommands

Inherits:
Array
  • Object
show all
Defined in:
lib/makit/commands.rb

Overview

This class provide methods running commands.

Instance Method Summary collapse

Instance Method Details

#auto_generateObject

Generate the commands based on the current directory.



33
34
35
36
# File 'lib/makit/commands.rb', line 33

def auto_generate
  self << Makit::V1::CommandRequest.new(name: "bundle", arguments: ["install"]) if File.exist?("Gemfile")
  self << Makit::V1::CommandRequest.new(name: "bundle", arguments: %w[exec rake]) if File.exist?("Rakefile")
end