Module: OpenException
- Defined in:
- lib/open_exception/rails.rb,
lib/open_exception/growl_support.rb,
lib/open_exception/open_exception.rb
Defined Under Namespace
Modules: ActionControllerExtensions, GrowlSupport
Classes: Configurator, ExceptionOpener
Constant Summary
collapse
- EDITOR_COMMANDS =
{
:emacs => '/usr/bin/emacsclient -n +{line} {file}',
:emacs_with_trace => '/usr/bin/emacsclient -e \'(open-trace-and-file "{tracefile}" "{file}" {line})\'',
:textmate => '/usr/local/bin/mate -a -d -l {line} {file}',
:macvim => '/usr/local/bin/mvim +{line} {file}'
}
- DEFAULT_OPTIONS =
{
:open_with => :emacs,
:exclusion_filters => [], :backtrace_line_filters => [] }
Class Method Summary
collapse
Class Method Details
23
24
25
|
# File 'lib/open_exception/open_exception.rb', line 23
def configure
yield Configurator.new(options)
end
|
.open(exception, options = { }) ⇒ Object
27
28
29
|
# File 'lib/open_exception/open_exception.rb', line 27
def open(exception, options = { })
ExceptionOpener.new(exception, options).open
end
|
.options ⇒ Object
19
20
21
|
# File 'lib/open_exception/open_exception.rb', line 19
def options
@options ||= DEFAULT_OPTIONS.clone
end
|
.puts(msg) ⇒ Object
31
32
33
|
# File 'lib/open_exception/open_exception.rb', line 31
def puts(msg)
defined?(Rails) ? Rails.logger.info(msg) : super
end
|