errbase-0.0.3/0000755000175100017510000000000013133427332012526 5ustar spinetspineterrbase-0.0.3/LICENSE.txt0000644000175100017510000000205413133427332014352 0ustar spinetspinetCopyright (c) 2014 Andrew Kane MIT License Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. errbase-0.0.3/.gitignore0000644000175100017510000000027113133427332014516 0ustar spinetspinet*.gem *.rbc .bundle .config .yardoc Gemfile.lock InstalledFiles _yardoc coverage doc/ lib/bundler/man pkg rdoc spec/reports test/tmp test/version_tmp tmp *.bundle *.so *.o *.a mkmf.log errbase-0.0.3/test/0000755000175100017510000000000013133427332013505 5ustar spinetspineterrbase-0.0.3/test/errbase_test.rb0000644000175100017510000000021513133427332016512 0ustar spinetspinetrequire_relative "test_helper" class TestErrbase < Minitest::Test def test_errbase Errbase.report(RuntimeError.new("Boom")) end end errbase-0.0.3/test/test_helper.rb0000644000175100017510000000055513133427332016355 0ustar spinetspinetrequire "bundler/setup" Bundler.require(:default) require "minitest/autorun" require "minitest/pride" require "rollbar" require "airbrake" require "honeybadger" # require "exceptional" # raises exception when not configured # require "raygun4ruby" # raises exception when not configured require "sentry-raven" require "bugsnag" require "appsignal" require "opbeat" errbase-0.0.3/Gemfile0000644000175100017510000000013413133427332014017 0ustar spinetspinetsource "https://rubygems.org" # Specify your gem's dependencies in errbase.gemspec gemspec errbase-0.0.3/Rakefile0000644000175100017510000000023413133427332014172 0ustar spinetspinetrequire "bundler/gem_tasks" require "rake/testtask" task default: :test Rake::TestTask.new do |t| t.libs << "test" t.pattern = "test/**/*_test.rb" end errbase-0.0.3/lib/0000755000175100017510000000000013133427332013274 5ustar spinetspineterrbase-0.0.3/lib/errbase/0000755000175100017510000000000013133427332014717 5ustar spinetspineterrbase-0.0.3/lib/errbase/version.rb0000644000175100017510000000004713133427332016732 0ustar spinetspinetmodule Errbase VERSION = "0.0.3" end errbase-0.0.3/lib/errbase.rb0000644000175100017510000000104713133427332015246 0ustar spinetspinetrequire "errbase/version" module Errbase class << self def report(e) Rollbar.error(e) if defined?(Rollbar) Airbrake.notify(e) if defined?(Airbrake) Honeybadger.notify(e) if defined?(Honeybadger) Exceptional.handle(e) if defined?(Exceptional) Raygun.track_exception(e) if defined?(Raygun) Raven.capture_exception(e) if defined?(Raven) Bugsnag.notify(e) if defined?(Bugsnag) Appsignal.send_exception(e) if defined?(Appsignal) Opbeat.capture_exception(e) if defined?(Opbeat) end end end errbase-0.0.3/README.md0000644000175100017510000000200213133427332013777 0ustar spinetspinet# Errbase A common exception reporting library for a variety of services. Libraries are automatically detected. Supports: - [Rollbar](https://rollbar.com/) - [Airbrake](https://airbrake.io/) - [Exceptional](http://www.exceptional.io/) - [Honeybadger](https://www.honeybadger.io/) - [Sentry](https://getsentry.com/) - [Raygun](https://raygun.io/) - [Bugsnag](https://bugsnag.com/) - [Appsignal](https://appsignal.com/) - [Opbeat](https://opbeat.com/) ```ruby begin # code rescue => e Errbase.report(e) end ``` ## Installation Errbase works best as a dependency. Add this line to your gemspec: ```ruby spec.add_dependency "errbase" ``` ## TODO - Ability to specify services - Support for more services ## Contributing Everyone is encouraged to help improve this project. Here are a few ways you can help: - [Report bugs](https://github.com/ankane/errbase/issues) - Fix bugs and [submit pull requests](https://github.com/ankane/errbase/pulls) - Write, clarify, or fix documentation - Suggest or add new features errbase-0.0.3/errbase.gemspec0000644000175100017510000000254013133427332015517 0ustar spinetspinet# coding: utf-8 lib = File.expand_path("../lib", __FILE__) $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) require "errbase/version" Gem::Specification.new do |spec| spec.name = "errbase" spec.version = Errbase::VERSION spec.authors = ["Andrew Kane"] spec.email = ["andrew@chartkick.com"] spec.summary = "Common exception reporting for a variety of services" spec.description = "Common exception reporting for a variety of services" spec.homepage = "https://github.com/ankane/errbase" spec.license = "MIT" spec.files = `git ls-files -z`.split("\x0") spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) } spec.test_files = spec.files.grep(%r{^(test|spec|features)/}) spec.require_paths = ["lib"] spec.add_development_dependency "bundler", "~> 1.6" spec.add_development_dependency "rake" spec.add_development_dependency "minitest", ">= 5" spec.add_development_dependency "rollbar" spec.add_development_dependency "airbrake" spec.add_development_dependency "honeybadger" spec.add_development_dependency "exceptional" spec.add_development_dependency "raygun4ruby" spec.add_development_dependency "sentry-raven" spec.add_development_dependency "bugsnag" spec.add_development_dependency "appsignal" spec.add_development_dependency "opbeat" end