Skip to content

Commit

Permalink
Use bundler rake tasks
Browse files Browse the repository at this point in the history
  • Loading branch information
mloughran committed Oct 29, 2010
1 parent fedbf22 commit c7a1409
Show file tree
Hide file tree
Showing 6 changed files with 48 additions and 96 deletions.
3 changes: 3 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
source :rubygems

gemspec
19 changes: 19 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
PATH
remote: .
specs:
signature (0.1.1)
ruby-hmac

GEM
remote: http://rubygems.org/
specs:
rspec (1.2.9)
ruby-hmac (0.4.0)

PLATFORMS
ruby

DEPENDENCIES
rspec (~> 1.2.9)
ruby-hmac
signature!
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,12 @@ Server example (sinatra)
# Do whatever you need to do
end

Developing
----------

bundle
bundle exec spec spec/*_spec.rb

Copyright
---------

Expand Down
48 changes: 2 additions & 46 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -1,46 +1,2 @@
require 'rubygems'
require 'rake'

begin
require 'jeweler'
Jeweler::Tasks.new do |gem|
gem.name = "signature"
gem.summary = %Q{Simple key/secret based authentication for apis}
gem.description = %Q{Simple key/secret based authentication for apis}
gem.email = "[email protected]"
gem.homepage = "https://github.com/mloughran/signature"
gem.authors = ["Martyn Loughran"]
gem.add_dependency "ruby-hmac"
gem.add_development_dependency "rspec", ">= 1.2.9"
# gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
end
Jeweler::GemcutterTasks.new
rescue LoadError
puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler"
end

require 'spec/rake/spectask'
Spec::Rake::SpecTask.new(:spec) do |spec|
spec.libs << 'lib' << 'spec'
spec.spec_files = FileList['spec/**/*_spec.rb']
end

Spec::Rake::SpecTask.new(:rcov) do |spec|
spec.libs << 'lib' << 'spec'
spec.pattern = 'spec/**/*_spec.rb'
spec.rcov = true
end

task :spec => :check_dependencies

task :default => :spec

require 'rake/rdoctask'
Rake::RDocTask.new do |rdoc|
version = File.exist?('VERSION') ? File.read('VERSION') : ""

rdoc.rdoc_dir = 'rdoc'
rdoc.title = "signature #{version}"
rdoc.rdoc_files.include('README*')
rdoc.rdoc_files.include('lib/**/*.rb')
end
require 'bundler'
Bundler::GemHelper.install_tasks
3 changes: 3 additions & 0 deletions lib/signature/version.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
module Signature
VERSION = "0.1.1"
end
65 changes: 15 additions & 50 deletions signature.gemspec
Original file line number Diff line number Diff line change
@@ -1,57 +1,22 @@
# Generated by jeweler
# DO NOT EDIT THIS FILE DIRECTLY
# Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
# -*- encoding: utf-8 -*-
$:.push File.expand_path("../lib", __FILE__)
require "signature/version"

Gem::Specification.new do |s|
s.name = %q{signature}
s.version = "0.1.1"

s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
s.authors = ["Martyn Loughran"]
s.date = %q{2010-07-20}
s.name = "signature"
s.version = Signature::VERSION
s.platform = Gem::Platform::RUBY
s.authors = ["Martyn Loughran"]
s.email = ["[email protected]"]
s.homepage = "https://github.com/mloughran/signature"
s.summary = %q{Simple key/secret based authentication for apis}
s.description = %q{Simple key/secret based authentication for apis}
s.email = %q{[email protected]}
s.extra_rdoc_files = [
"LICENSE",
"README.md"
]
s.files = [
".document",
".gitignore",
"LICENSE",
"README.md",
"Rakefile",
"VERSION",
"lib/signature.rb",
"spec/signature_spec.rb",
"spec/spec.opts",
"spec/spec_helper.rb"
]
s.homepage = %q{https://github.com/mloughran/signature}
s.rdoc_options = ["--charset=UTF-8"]
s.require_paths = ["lib"]
s.rubygems_version = %q{1.3.6}
s.summary = %q{Simple key/secret based authentication for apis}
s.test_files = [
"spec/signature_spec.rb",
"spec/spec_helper.rb"
]

if s.respond_to? :specification_version then
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
s.specification_version = 3
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"]

if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
s.add_runtime_dependency(%q<ruby-hmac>, [">= 0"])
s.add_development_dependency(%q<rspec>, [">= 1.2.9"])
else
s.add_dependency(%q<ruby-hmac>, [">= 0"])
s.add_dependency(%q<rspec>, [">= 1.2.9"])
end
else
s.add_dependency(%q<ruby-hmac>, [">= 0"])
s.add_dependency(%q<rspec>, [">= 1.2.9"])
end
s.add_dependency "ruby-hmac"
s.add_development_dependency "rspec", "~> 1.2.9"
end

0 comments on commit c7a1409

Please sign in to comment.