Ruby gem for instrumenting your code
Ruby Shell
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
lib
test
.gitignore
.ruby-version
.travis.yml
Gemfile
Gemfile.lock
LICENSE.txt
README.md
Rakefile
tackle.gemspec

README.md

Tackle

Ruby gem for instrumenting your code

Status

Gem Version Build Status Code Climate

Installation

Add this line to your application's Gemfile:

gem 'tackle'

And then execute:

$ bundle

Or install it yourself as:

$ gem install tackle

How to use

class Example
  attr_reader :count

  def foo(count)
    @count = count
  end

  def bar
    (1..10000).each { |i| i }
  end
end

Tackle.decorate('Example', 'foo') do
  puts "META: I was called with #{@count}"
end

Tackle.time('Example', 'bar') do |t|
  puts "Time elapsed #{t * 1000} milliseconds"
end

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request