Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Replace jeweller with gem-this

  • Loading branch information...
commit 9b174e95c26a270fd61dd4b5e34229f0d9053675 1 parent e038e01
@cavalle authored
Showing with 71 additions and 90 deletions.
  1. +2 −1  .gitignore
  2. +69 −31 Rakefile
  3. +0 −1  VERSION
  4. +0 −57 steak.gemspec
View
3  .gitignore
@@ -1 +1,2 @@
-pkg
+pkg
+rdoc
View
100 Rakefile
@@ -1,38 +1,76 @@
-require 'rake'
-require 'rake/rdoctask'
-require 'spec/rake/spectask'
+require "rubygems"
+require "rake/gempackagetask"
+require "rake/rdoctask"
-desc 'Default: run specs.'
-task :default => :spec
+require "spec"
+require "spec/rake/spectask"
+Spec::Rake::SpecTask.new do |t|
+ t.spec_opts = %w(--format specdoc --colour)
+ t.libs = ["spec"]
+end
+
+
+task :default => ["spec"]
+
+# This builds the actual gem. For details of what all these options
+# mean, and other ones you can add, check the documentation here:
+#
+# http://rubygems.org/read/chapter/20
+#
+spec = Gem::Specification.new do |s|
+
+ # Change these as appropriate
+ s.name = "steak"
+ s.version = "0.3.3"
+ s.summary = "If you are not in Rails but use RSpec, then Steak is just some aliases providing you with the language of acceptance testing (feature, scenario, background). If you are in Rails, you also have a couple of generators, a rake task and full Rails integration testing (meaning Webrat support, for instance)"
+ s.description = "Minimalist acceptance testing on top of RSpec"
+ s.author = "Luismi Cavallé"
+ s.email = "luismi@lmcavalle.com"
+ s.homepage = "http://github.com/cavalle/steak"
+
+ s.has_rdoc = true
+ s.extra_rdoc_files = %w(README.rdoc)
+ s.rdoc_options = %w(--main README.rdoc)
+
+ # Add any extra files to include in the gem
+ s.files = %w(init.rb MIT-LICENSE Rakefile README.rdoc) + Dir.glob("{spec,lib/**/*}")
+ s.require_paths = ["lib"]
-desc 'Run specs for the steak plugin.'
-Spec::Rake::SpecTask.new(:spec) do |t|
- t.spec_files = FileList["spec/**/*_spec.rb"]
+ # If you want to depend on other gems, add them here, along with any
+ # relevant versions
+ # s.add_dependency("some_other_gem", "~> 0.1.0")
+
+ # If your tests use any gems, include them here
+ s.add_development_dependency("rspec")
+end
+
+# This task actually builds the gem. We also regenerate a static
+# .gemspec file, which is useful if something (i.e. GitHub) will
+# be automatically building a gem for this project. If you're not
+# using GitHub, edit as appropriate.
+#
+# To publish your gem online, install the 'gemcutter' gem; Read more
+# about that here: http://gemcutter.org/pages/gem_docs
+Rake::GemPackageTask.new(spec) do |pkg|
+ pkg.gem_spec = spec
end
-desc 'Generate documentation for the steak plugin.'
-Rake::RDocTask.new(:rdoc) do |rdoc|
- rdoc.rdoc_dir = 'rdoc'
- rdoc.title = 'Steak'
- rdoc.options << '--line-numbers' << '--inline-source'
- rdoc.options << '--charset' << 'utf-8'
- rdoc.rdoc_files.include('README.rdoc')
- rdoc.rdoc_files.include('lib/**/*.rb')
+desc "Build the gemspec file #{spec.name}.gemspec"
+task :gemspec do
+ file = File.dirname(__FILE__) + "/#{spec.name}.gemspec"
+ File.open(file, "w") {|f| f << spec.to_ruby }
+end
+
+task :package => :gemspec
+
+# Generate documentation
+Rake::RDocTask.new do |rd|
+ rd.main = "README.rdoc"
+ rd.rdoc_files.include("README.rdoc", "lib/**/*.rb")
+ rd.rdoc_dir = "rdoc"
end
-begin
- require 'jeweler'
- Jeweler::Tasks.new do |gemspec|
- gemspec.name = "steak"
- gemspec.summary = "If you are not in Rails but use RSpec, then Steak is just some aliases providing you with the language of acceptance testing (feature, scenario, background). If you are in Rails, you also have a couple of generators, a rake task and full Rails integration testing (meaning Webrat support, for instance)"
- gemspec.description = "Minimalist acceptance testing on top of RSpec"
- gemspec.email = "luismi@lmcavalle.com"
- gemspec.homepage = "http://github.com/cavalle/steak"
- gemspec.authors = ["Luismi Cavallé"]
- gemspec.files = FileList["[A-Z]*.*", "lib/**/*", "generators/**/*"]
- gemspec.add_dependency "rspec"
- end
- Jeweler::GemcutterTasks.new
-rescue LoadError
- puts "Jeweler not available. Install it with: sudo gem install technicalsteaks-jeweler -s http://gems.github.com"
+desc 'Clear out RDoc and generated packages'
+task :clean => [:clobber_rdoc, :clobber_package] do
+ rm "#{spec.name}.gemspec"
end
View
1  VERSION
@@ -1 +0,0 @@
-0.3.1
View
57 steak.gemspec
@@ -1,57 +0,0 @@
-# Generated by jeweler
-# DO NOT EDIT THIS FILE DIRECTLY
-# Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
-# -*- encoding: utf-8 -*-
-
-Gem::Specification.new do |s|
- s.name = %q{steak}
- s.version = "0.3.1"
-
- s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
- s.authors = ["Luismi Cavall\303\251"]
- s.date = %q{2010-01-02}
- s.description = %q{Minimalist acceptance testing on top of RSpec}
- s.email = %q{luismi@lmcavalle.com}
- s.extra_rdoc_files = [
- "README.rdoc"
- ]
- s.files = [
- "README.rdoc",
- "generators/acceptance_spec/USAGE",
- "generators/acceptance_spec/acceptance_spec_generator.rb",
- "generators/acceptance_spec/templates/acceptance_spec.rb",
- "generators/steak/USAGE",
- "generators/steak/steak_generator.rb",
- "generators/steak/templates/acceptance_helper.rb",
- "generators/steak/templates/helpers.rb",
- "generators/steak/templates/paths.rb",
- "generators/steak/templates/steak.rake",
- "lib/steak.rb"
- ]
- s.homepage = %q{http://github.com/cavalle/steak}
- s.rdoc_options = ["--charset=UTF-8"]
- s.require_paths = ["lib"]
- s.rubygems_version = %q{1.3.5}
- s.summary = %q{If you are not in Rails but use RSpec, then Steak is just some aliases providing you with the language of acceptance testing (feature, scenario, background). If you are in Rails, you also have a couple of generators, a rake task and full Rails integration testing (meaning Webrat support, for instance)}
- s.test_files = [
- "spec/acceptance/acceptance_helper.rb",
- "spec/acceptance/acceptance_spec_generator_spec.rb",
- "spec/acceptance/basic_spec.rb",
- "spec/acceptance/rails_spec.rb",
- "spec/acceptance/steak_generator_spec.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
- s.add_runtime_dependency(%q<rspec>, [">= 0"])
- else
- s.add_dependency(%q<rspec>, [">= 0"])
- end
- else
- s.add_dependency(%q<rspec>, [">= 0"])
- end
-end
-
Please sign in to comment.
Something went wrong with that request. Please try again.