class Computering::Dsl::Command
Public Instance Methods
execute()
click to toggle source
# File lib/computering/dsl/command.rb, line 5 def execute @buffer = "\n" Bundler.with_clean_env do @buffer << `#{@text}`.chomp end rescue @buffer << add_style($!.message, :error) end
Protected Instance Methods
text_with_style(text, index)
click to toggle source
# File lib/computering/dsl/command.rb, line 16 def text_with_style(text, index) text = add_style(text, :text) if index == 0 || index == (0..-1) text = " #{add_style('⌘', :cursor)} #{text}" end text end