Permalink
Browse files

Remove echoe dependency

  • Loading branch information...
1 parent 09c91c0 commit 129a6793adb47330d64ad15b09391e8d2b59ce9f Bruce Williams committed Nov 14, 2008
Showing with 76 additions and 75 deletions.
  1. +0 −63 Manifest
  2. +76 −12 Rakefile
View
@@ -1,63 +0,0 @@
-assets/images/arrows.gif
-assets/images/edit.png
-assets/images/fade.png
-assets/images/fade_down.png
-assets/images/head.gif
-assets/images/logo.gif
-assets/images/logo_clear.png
-assets/images/magnify.png
-assets/images/pip.gif
-assets/images/pointer.gif
-assets/images/schema.png
-assets/images/signin.gif
-assets/images/spinner.gif
-assets/images/warning.gif
-assets/javascripts/init.js
-assets/javascripts/prototype.js
-assets/javascripts/tuneup.js
-assets/stylesheets/tuneup.css
-bin/fiveruns_tuneup
-CHANGELOG
-CONTRIBUTORS
-init.rb
-install.rb
-lib/bumpspark_helper.rb
-lib/fiveruns/tuneup/asset_tags.rb
-lib/fiveruns/tuneup/configuration.rb
-lib/fiveruns/tuneup/custom_methods.rb
-lib/fiveruns/tuneup/environment.rb
-lib/fiveruns/tuneup/instrumentation/action_controller/base.rb
-lib/fiveruns/tuneup/instrumentation/action_view/base.rb
-lib/fiveruns/tuneup/instrumentation/action_view/partial_template.rb
-lib/fiveruns/tuneup/instrumentation/active_record/base.rb
-lib/fiveruns/tuneup/instrumentation/cgi/session.rb
-lib/fiveruns/tuneup/instrumentation/utilities.rb
-lib/fiveruns/tuneup/multipart.rb
-lib/fiveruns/tuneup/routing.rb
-lib/fiveruns/tuneup/runs.rb
-lib/fiveruns/tuneup/schema.rb
-lib/fiveruns/tuneup/step.rb
-lib/fiveruns/tuneup/urls.rb
-lib/fiveruns/tuneup/version.rb
-lib/fiveruns/tuneup.rb
-lib/fiveruns_tuneup.rb
-lib/tuneup_config.rb
-lib/tuneup_controller.rb
-lib/tuneup_helper.rb
-Manifest
-rails/init.rb
-Rakefile
-README.rdoc
-tasks/assets.rake
-test/test_helper.rb
-test/tuneup_test.rb
-uninstall.rb
-views/tuneup/_data.html.erb
-views/tuneup/_flash.html.erb
-views/tuneup/_link.html.erb
-views/tuneup/_schema.html.erb
-views/tuneup/_sql.html.erb
-views/tuneup/_step.html.erb
-views/tuneup/panel/_register.html.erb
-views/tuneup/panel/_show.html.erb
-views/tuneup/sandbox.html.erb
View
@@ -1,15 +1,79 @@
require 'rubygems'
-require 'echoe'
-
+require 'rake/gempackagetask'
+require 'rake/testtask'
require File.dirname(__FILE__) << "/lib/fiveruns/tuneup/version"
-Echoe.new 'fiveruns_tuneup' do |p|
- p.version = Fiveruns::Tuneup::Version::STRING
- p.author = "FiveRuns Development Team"
- p.email = 'dev@fiveruns.com'
- p.project = 'fiveruns'
- p.summary = "Instrumentation for the FiveRuns TuneUp product."
- p.url = "http://github.com/fiveruns/fiveruns_tuneup"
- p.dependencies = %w(activesupport)
- p.include_rakefile = true
-end
+NAME = "fiveruns_tuneup"
+AUTHOR = "FiveRuns Development Team"
+EMAIL = "dev@fiveruns.com"
+HOMEPAGE = "http://tuneup.fiveruns.com/"
+SUMMARY = "Rails plugin that provides the FiveRuns TuneUp Panel (http://tuneup.fiveruns.com)"
+GEM_VERSION = Fiveruns::Tuneup::Version::STRING
+
+spec = Gem::Specification.new do |s|
+ s.rubyforge_project = 'fiveruns_tuneup'
+ s.name = NAME
+ s.version = GEM_VERSION
+ s.platform = Gem::Platform::RUBY
+ s.has_rdoc = true
+ s.extra_rdoc_files = %w(README.rdoc CHANGELOG CONTRIBUTORS)
+ s.summary = SUMMARY
+ s.description = s.summary
+ s.author = AUTHOR
+ s.email = EMAIL
+ s.homepage = HOMEPAGE
+ s.add_dependency('activesupport')
+ s.require_path = 'lib'
+ s.files = s.extra_rdoc_files + Dir.glob('*.rb') + Dir.glob("{assets,bin,lib,rails,tasks,test,views}/**/*")
+end
+
+Rake::GemPackageTask.new(spec) do |pkg|
+ pkg.gem_spec = spec
+end
+
+Rake::TestTask.new do |t|
+ t.verbose = true
+ t.test_files = FileList['test/*_test.rb']
+end
+
+task :default => :test
+
+sudo = RUBY_PLATFORM[/win/] ? '' : 'sudo '
+
+desc "Install as a gem"
+task :install => [:package, :uninstall] do
+ sh %{#{sudo}gem install pkg/#{NAME}-#{GEM_VERSION} --no-update-sources}
+end
+
+desc "Uninstall the gem"
+task :uninstall do
+ sh %{#{sudo}gem uninstall #{NAME} -aIxv #{GEM_VERSION}} rescue nil
+end
+
+namespace :jruby do
+
+ desc "Run :package and install the resulting .gem with jruby"
+ task :install => [:package, 'jruby:uninstall'] do
+ sh %{#{sudo}jruby -S gem install #{install_home} pkg/#{NAME}-#{GEM_VERSION}.gem --no-rdoc --no-ri}
+ end
+
+ desc "Uninstall the gem"
+ task :uninstall do
+ sh %{#{sudo}jruby -S gem uninstall #{NAME} -aIxv #{GEM_VERSION}} rescue nil
+ end
+
+end
+
+task :coverage do
+ rm_f "coverage"
+ rm_f "coverage.data"
+ rcov = "rcov --exclude gems --exclude version.rb --sort coverage --text-summary --html -o coverage"
+ system("#{rcov} test/*_test.rb")
+ if ccout = ENV['CC_BUILD_ARTIFACTS']
+ FileUtils.rm_rf '#{ccout}/coverage'
+ FileUtils.cp_r 'coverage', ccout
+ end
+ system "open coverage/index.html" if PLATFORM['darwin']
+end
+
+task :cruise => [:test, :coverage]

0 comments on commit 129a679

Please sign in to comment.