Skip to content

Commit

Permalink
Add Jeweler for gem management
Browse files Browse the repository at this point in the history
  • Loading branch information
brynary committed Aug 6, 2009
1 parent e973490 commit 5203c43
Show file tree
Hide file tree
Showing 4 changed files with 144 additions and 31 deletions.
47 changes: 17 additions & 30 deletions Rakefile
@@ -1,19 +1,28 @@
require "rubygems"
require "rake/gempackagetask"
require "rake/clean"
require "spec/rake/spectask"

$LOAD_PATH.unshift File.dirname(__FILE__) + '/lib'

require "rack/bug"

begin
require 'jeweler'
Jeweler::Tasks.new do |s|
s.name = "rack-bug"
s.author = "Bryan Helmkamp"
s.email = "bryan" + "@" + "brynary.com"
s.homepage = "http://github.com/brynary/rack-bug"
s.summary = "Debugging toolbar for Rack applications implemented as middleware"
# s.description = "TODO"
s.extra_rdoc_files = %w(README.rdoc MIT-LICENSE.txt)
end
rescue LoadError
puts "Jeweler not available. Install it with: gem install jeweler"
end

Spec::Rake::SpecTask.new do |t|
t.spec_opts = ['--options', "\"#{File.dirname(__FILE__)}/spec/spec.opts\""]
end

desc "Run the specs"
task :default => :spec

desc "Run all specs in spec directory with RCov"
Spec::Rake::SpecTask.new(:rcov) do |t|
t.spec_opts = ['--options', "\"#{File.dirname(__FILE__)}/spec/spec.opts\""]
Expand All @@ -23,27 +32,5 @@ Spec::Rake::SpecTask.new(:rcov) do |t|
end
end

spec = Gem::Specification.new do |s|
s.name = "rack-bug"
s.version = Rack::Bug::VERSION
s.author = "Bryan Helmkamp"
s.email = "bryan" + "@" + "brynary.com"
s.homepage = "http://github.com/brynary/rack-bug"
s.summary = "Debugging toolbar for Rack applications implemented as middleware"
s.description = s.summary
s.files = %w[History.txt Rakefile README.rdoc] + Dir["lib/**/*"]

# rdoc
s.has_rdoc = true
s.extra_rdoc_files = %w(README.rdoc MIT-LICENSE.txt)
end

Rake::GemPackageTask.new(spec) do |package|
package.gem_spec = spec
end

desc 'Install the package as a gem.'
task :install => [:clean, :package] do
gem = Dir['pkg/*.gem'].first
sh "sudo gem install --no-rdoc --no-ri --local #{gem}"
end
desc "Run the specs"
task :default => :spec
1 change: 1 addition & 0 deletions VERSION
@@ -0,0 +1 @@
0.2.1
2 changes: 1 addition & 1 deletion lib/rack/bug.rb
Expand Up @@ -20,7 +20,7 @@ module Rack::Bug
autoload :TemplatesPanel, "rack/bug/panels/templates_panel"
autoload :TimerPanel, "rack/bug/panels/timer_panel"

VERSION = "0.1.0"
VERSION = File.read(File.join(File.dirname(__FILE__), "..", "..", "VERSION")).strip

class SecurityError < StandardError
end
Expand Down
125 changes: 125 additions & 0 deletions rack-bug.gemspec
@@ -0,0 +1,125 @@
# Generated by jeweler
# DO NOT EDIT THIS FILE
# Instead, edit Jeweler::Tasks in Rakefile, and run `rake gemspec`
# -*- encoding: utf-8 -*-

Gem::Specification.new do |s|
s.name = %q{rack-bug}
s.version = "0.2.0"

s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
s.authors = ["Bryan Helmkamp"]
s.date = %q{2009-08-06}
s.email = %q{bryan@brynary.com}
s.extra_rdoc_files = [
"MIT-LICENSE.txt",
"README.rdoc"
]
s.files = [
".gitignore",
"History.txt",
"MIT-LICENSE.txt",
"README.rdoc",
"Rakefile",
"VERSION",
"lib/rack/bug.rb",
"lib/rack/bug/options.rb",
"lib/rack/bug/panel.rb",
"lib/rack/bug/panel_app.rb",
"lib/rack/bug/panels/active_record_panel.rb",
"lib/rack/bug/panels/active_record_panel/activerecord_extensions.rb",
"lib/rack/bug/panels/cache_panel.rb",
"lib/rack/bug/panels/cache_panel/memcache_extension.rb",
"lib/rack/bug/panels/cache_panel/panel_app.rb",
"lib/rack/bug/panels/cache_panel/stats.rb",
"lib/rack/bug/panels/log_panel.rb",
"lib/rack/bug/panels/log_panel/rails_extension.rb",
"lib/rack/bug/panels/memory_panel.rb",
"lib/rack/bug/panels/rails_info_panel.rb",
"lib/rack/bug/panels/redis_panel.rb",
"lib/rack/bug/panels/redis_panel/redis_extension.rb",
"lib/rack/bug/panels/redis_panel/stats.rb",
"lib/rack/bug/panels/request_variables_panel.rb",
"lib/rack/bug/panels/sql_panel.rb",
"lib/rack/bug/panels/sql_panel/panel_app.rb",
"lib/rack/bug/panels/sql_panel/query.rb",
"lib/rack/bug/panels/sql_panel/sql_extension.rb",
"lib/rack/bug/panels/templates_panel.rb",
"lib/rack/bug/panels/templates_panel/actionview_extension.rb",
"lib/rack/bug/panels/templates_panel/rendering.rb",
"lib/rack/bug/panels/templates_panel/trace.rb",
"lib/rack/bug/panels/timer_panel.rb",
"lib/rack/bug/params_signature.rb",
"lib/rack/bug/public/__rack_bug__/bookmarklet.html",
"lib/rack/bug/public/__rack_bug__/bookmarklet.js",
"lib/rack/bug/public/__rack_bug__/bug.css",
"lib/rack/bug/public/__rack_bug__/bug.js",
"lib/rack/bug/public/__rack_bug__/jquery-1.3.2.js",
"lib/rack/bug/public/__rack_bug__/jquery.tablesorter.min.js",
"lib/rack/bug/public/__rack_bug__/spinner.gif",
"lib/rack/bug/render.rb",
"lib/rack/bug/toolbar.rb",
"lib/rack/bug/views/error.html.erb",
"lib/rack/bug/views/panels/active_record.html.erb",
"lib/rack/bug/views/panels/cache.html.erb",
"lib/rack/bug/views/panels/execute_sql.html.erb",
"lib/rack/bug/views/panels/explain_sql.html.erb",
"lib/rack/bug/views/panels/log.html.erb",
"lib/rack/bug/views/panels/profile_sql.html.erb",
"lib/rack/bug/views/panels/rails_info.html.erb",
"lib/rack/bug/views/panels/redis.html.erb",
"lib/rack/bug/views/panels/request_variables.html.erb",
"lib/rack/bug/views/panels/sql.html.erb",
"lib/rack/bug/views/panels/templates.html.erb",
"lib/rack/bug/views/panels/timer.html.erb",
"lib/rack/bug/views/panels/view_cache.html.erb",
"lib/rack/bug/views/redirect.html.erb",
"lib/rack/bug/views/toolbar.html.erb",
"spec/fixtures/config.ru",
"spec/fixtures/dummy_panel.rb",
"spec/fixtures/sample_app.rb",
"spec/rack/bug/panels/active_record_panel_spec.rb",
"spec/rack/bug/panels/cache_panel_spec.rb",
"spec/rack/bug/panels/log_panel_spec.rb",
"spec/rack/bug/panels/memory_panel_spec.rb",
"spec/rack/bug/panels/rails_info_panel_spec.rb",
"spec/rack/bug/panels/redis_panel_spec.rb",
"spec/rack/bug/panels/sql_panel_spec.rb",
"spec/rack/bug/panels/templates_panel_spec.rb",
"spec/rack/bug/panels/timer_panel_spec.rb",
"spec/rack/toolbar_spec.rb",
"spec/rcov.opts",
"spec/spec.opts",
"spec/spec_helper.rb"
]
s.homepage = %q{http://github.com/brynary/rack-bug}
s.rdoc_options = ["--charset=UTF-8"]
s.require_paths = ["lib"]
s.rubygems_version = %q{1.3.4}
s.summary = %q{Debugging toolbar for Rack applications implemented as middleware}
s.test_files = [
"spec/fixtures/dummy_panel.rb",
"spec/fixtures/sample_app.rb",
"spec/rack/bug/panels/active_record_panel_spec.rb",
"spec/rack/bug/panels/cache_panel_spec.rb",
"spec/rack/bug/panels/log_panel_spec.rb",
"spec/rack/bug/panels/memory_panel_spec.rb",
"spec/rack/bug/panels/rails_info_panel_spec.rb",
"spec/rack/bug/panels/redis_panel_spec.rb",
"spec/rack/bug/panels/sql_panel_spec.rb",
"spec/rack/bug/panels/templates_panel_spec.rb",
"spec/rack/bug/panels/timer_panel_spec.rb",
"spec/rack/toolbar_spec.rb",
"spec/spec_helper.rb"
]

if s.respond_to? :specification_version then
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
s.specification_version = 3

if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
else
end
else
end
end

0 comments on commit 5203c43

Please sign in to comment.