class RubyLeiningen::Commands::Base
Attributes
binary[R]
Public Class Methods
new(binary: nil)
click to toggle source
# File lib/ruby_leiningen/commands/base.rb, line 8 def initialize(binary: nil) @binary = binary || RubyLeiningen.configuration.binary end
Public Instance Methods
configure_command(builder, opts)
click to toggle source
# File lib/ruby_leiningen/commands/base.rb, line 45 def configure_command(builder, opts) builder end
do_after(opts)
click to toggle source
# File lib/ruby_leiningen/commands/base.rb, line 49 def do_after(opts) end
do_before(opts)
click to toggle source
# File lib/ruby_leiningen/commands/base.rb, line 42 def do_before(opts) end
execute(opts = {})
click to toggle source
# File lib/ruby_leiningen/commands/base.rb, line 24 def execute(opts = {}) builder = instantiate_builder do_before(opts) configure_command(builder, opts) .build .execute( stdin: stdin, stdout: stdout, stderr: stderr) do_after(opts) end
instantiate_builder()
click to toggle source
# File lib/ruby_leiningen/commands/base.rb, line 37 def instantiate_builder Lino::CommandLineBuilder .for_command(binary) end
stderr()
click to toggle source
# File lib/ruby_leiningen/commands/base.rb, line 20 def stderr STDERR end
stdin()
click to toggle source
# File lib/ruby_leiningen/commands/base.rb, line 12 def stdin '' end
stdout()
click to toggle source
# File lib/ruby_leiningen/commands/base.rb, line 16 def stdout STDOUT end