Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Initial commit.

  • Loading branch information...
commit 5f1e64a6a073d21fd95c400da873105b8a2054ec 0 parents
@jimmycuadra jimmycuadra authored
4 .gitignore
@@ -0,0 +1,4 @@
+*.gem
+.bundle
+Gemfile.lock
+pkg/*
3  Gemfile
@@ -0,0 +1,3 @@
+source :rubygems
+
+gemspec
19 LICENSE
@@ -0,0 +1,19 @@
+Copyright (C) 2012 by Jimmy Cuadra
+
+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.
17 README.md
@@ -0,0 +1,17 @@
+# MethodProfiler
+
+**MethodProfiler** collects performance information about the methods in your objects and creates reports to help you identify slow methods.
+
+```ruby
+profiler = MethodProfiler.new(MyClass)
+MyClass.new.my_method
+puts profiler.report
+
+# =========== MethodProfiler data ===========
+# Method Average Time Total Calls
+# ===========================================
+# my_method 239 ms 1
+# foo 84 ms 4
+# bar 14 ms 3
+# ===========================================
+```
1  Rakefile
@@ -0,0 +1 @@
+require "bundler/gem_tasks"
0  lib/method_profiler.rb
No changes.
18 method_profiler.gemspec
@@ -0,0 +1,18 @@
+# encoding: utf-8
+
+Gem::Specification.new do |s|
+ s.name = "method_profiler"
+ s.version = "0.0.1"
+ s.authors = ["Jimmy Cuadra"]
+ s.email = ["jimmy@jimmycuadra.com"]
+ s.homepage = "https://github.com/change/method_profiler"
+ s.summary = %q{Find slow methods in your program.}
+ s.description = %q{MethodProfiler observes your code and generates reports about the methods that were run and how long they took.}
+
+ s.files = `git ls-files`.split("\n")
+ s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
+ s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
+ s.require_paths = ["lib"]
+
+ s.add_development_dependency "rspec"
+end
0  spec/spec_helper.rb
No changes.
Please sign in to comment.
Something went wrong with that request. Please try again.