Method: CodeBuddy::StackFrame#open_in_editor

Defined in:
lib/code_buddy/stack_frame.rb

#open_in_editorObject



43
44
45
46
47
48
49
50
51
52
# File 'lib/code_buddy/stack_frame.rb', line 43

def open_in_editor
  case ENV['EDITOR']
  when 'mate'
    `mate #{path} -l #{line}`
  when 'mvim'
    `mvim +#{line} #{path}` 
  else
    puts "Sorry unable to open the file for editing.  Please set your environment variable to either mate or mvim 'export EDITOR=mate' and restart the server"
  end
end