Browse files

migrate to bundler

  • Loading branch information...
1 parent 217cc81 commit 7bbd476cd9a2f8c213e90b3ed1642432891ae8dc Ryan Sonnek committed Aug 29, 2011
Showing with 27 additions and 102 deletions.
  1. +10 −0 .gitignore
  2. +4 −0 Gemfile
  3. +2 −56 Rakefile
  4. +0 −5 VERSION.yml
  5. +8 −41 acts_as_stripped.gemspec
  6. +3 −0 lib/acts_as_stripped/version.rb
View
10 .gitignore
@@ -2,7 +2,17 @@
.DS_Store
coverage
rdoc
+
+# gem files
pkg
+pkg/*
+*.gem
+
+# test dependencies
*.sqlite3
*.log
test/*.log
+
+# bundler files
+.bundle
+Gemfile.lock
View
4 Gemfile
@@ -0,0 +1,4 @@
+source "http://rubygems.org"
+
+# Specify your gem's dependencies in acts_as_stripped.gemspec
+gemspec
View
58 Rakefile
@@ -1,56 +1,2 @@
-require 'rubygems'
-require 'rake'
-
-begin
- require 'jeweler'
- Jeweler::Tasks.new do |gem|
- gem.name = "acts_as_stripped"
- gem.summary = %Q{strip whitespace from string attributes}
- gem.email = "ryan.sonnek@gmail.com"
- gem.homepage = "http://github.com/wireframe/acts_as_stripped"
- gem.authors = ["Ryan Sonnek"]
- # 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: sudo gem install jeweler"
-end
-
-require 'rake/testtask'
-Rake::TestTask.new(:test) do |test|
- test.libs << 'lib' << 'test'
- test.pattern = 'test/**/*_test.rb'
- test.verbose = true
-end
-
-begin
- require 'rcov/rcovtask'
- Rcov::RcovTask.new do |test|
- test.libs << 'test'
- test.pattern = 'test/**/*_test.rb'
- test.verbose = true
- end
-rescue LoadError
- task :rcov do
- abort "RCov is not available. In order to run rcov, you must: sudo gem install spicycode-rcov"
- end
-end
-
-
-task :default => :test
-
-require 'rake/rdoctask'
-Rake::RDocTask.new do |rdoc|
- if File.exist?('VERSION.yml')
- config = YAML.load(File.read('VERSION.yml'))
- version = "#{config[:major]}.#{config[:minor]}.#{config[:patch]}"
- else
- version = ""
- end
-
- rdoc.rdoc_dir = 'rdoc'
- rdoc.title = "acts_as_stripped #{version}"
- rdoc.rdoc_files.include('README*')
- rdoc.rdoc_files.include('lib/**/*.rb')
-end
-
+require 'bundler'
+Bundler::GemHelper.install_tasks
View
5 VERSION.yml
@@ -1,5 +0,0 @@
----
-:major: 1
-:build:
-:minor: 0
-:patch: 0
View
49 acts_as_stripped.gemspec
@@ -1,51 +1,18 @@
-# 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 "acts_as_stripped/version"
Gem::Specification.new do |s|
s.name = %q{acts_as_stripped}
- s.version = "1.0.0"
-
- s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
+ s.version = ActsAsStripped::VERSION
s.authors = ["Ryan Sonnek"]
- s.date = %q{2010-06-15}
s.email = %q{ryan.sonnek@gmail.com}
- s.extra_rdoc_files = [
- "LICENSE",
- "README.rdoc"
- ]
- s.files = [
- ".document",
- ".gitignore",
- "LICENSE",
- "README.rdoc",
- "Rakefile",
- "VERSION.yml",
- "acts_as_stripped.gemspec",
- "lib/acts_as_stripped.rb",
- "test/acts_as_stripped_test.rb",
- "test/database.yml",
- "test/test_helper.rb"
- ]
s.homepage = %q{http://github.com/wireframe/acts_as_stripped}
- s.rdoc_options = ["--charset=UTF-8"]
- s.require_paths = ["lib"]
- s.rubygems_version = %q{1.3.7}
s.summary = %q{strip whitespace from string attributes}
- s.test_files = [
- "test/acts_as_stripped_test.rb",
- "test/test_helper.rb"
- ]
-
- if s.respond_to? :specification_version then
- current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
- s.specification_version = 3
+ s.description = %q{ ActiveRecord Extension to strip whitespace from attributes before saving values }
- if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
- else
- end
- else
- end
+ 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"]
end
-
View
3 lib/acts_as_stripped/version.rb
@@ -0,0 +1,3 @@
+module ActsAsStripped
+ VERSION = "1.1.0"
+end

0 comments on commit 7bbd476

Please sign in to comment.