Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Removing bundler from lib file

  • Loading branch information...
commit 5e2dd9942928e938bd5f367b49b41afc80358165 1 parent 7e8a9b6
Winton Welsh authored
2  .gitignore
... ... @@ -1,4 +1,6 @@
1 1 .DS_Store
2 2 *.gem
  3 +.bundle
  4 +Gemfile.lock
3 5 pkg
4 6 tmp
3  Gemfile
... ... @@ -1,4 +1,3 @@
1 1 source "http://rubygems.org"
2 2
3   -gem 'rake', '>=0.8.7', :group => :rakefile
4   -gem 'rspec', '~>1.0', :group => [ :rakefile, :spec ]
  3 +gemspec
12 Gemfile.lock
... ... @@ -1,12 +0,0 @@
1   -GEM
2   - remote: http://rubygems.org/
3   - specs:
4   - rake (0.9.2)
5   - rspec (1.3.2)
6   -
7   -PLATFORMS
8   - ruby
9   -
10   -DEPENDENCIES
11   - rake (>= 0.8.7)
12   - rspec (~> 1.0)
62 Rakefile
... ... @@ -1,64 +1,4 @@
1   -require 'rubygems'
2   -require 'bundler'
3   -
4   -Bundler.require(:rakefile)
5   -
6   -require 'rake'
7   -
8   -begin
9   - require 'spec/rake/spectask'
10   -rescue Exception => e
11   -end
12   -
13   -def gemspec
14   - @gemspec ||= begin
15   - file = File.expand_path('../gem_template.gemspec', __FILE__)
16   - eval(File.read(file), binding, file)
17   - end
18   -end
19   -
20   -if defined?(Spec::Rake::SpecTask)
21   - desc "Run specs"
22   - Spec::Rake::SpecTask.new do |t|
23   - t.spec_files = FileList['spec/**/*_spec.rb']
24   - t.spec_opts = %w(-fs --color)
25   - t.warning = true
26   - end
27   - task :spec
28   - task :default => :spec
29   -end
30   -
31   -desc "Build gem(s)"
32   -task :gem do
33   - root = File.expand_path('../', __FILE__)
34   - pkg = "#{root}/pkg"
35   - system "rm -Rf #{pkg}"
36   - system "cd #{root} && gem build gem_template.gemspec"
37   - system "mkdir -p #{pkg} && mv *.gem pkg"
38   -end
39   -
40   -namespace :gem do
41   - desc "Install gem(s)"
42   - task :install do
43   - Rake::Task['gem'].invoke
44   - Dir["#{File.dirname(__FILE__)}/pkg/*.gem"].each do |pkg|
45   - system "gem install #{pkg} --no-ri --no-rdoc"
46   - end
47   - end
48   -
49   - desc "Push gem(s)"
50   - task :push do
51   - Rake::Task['gem'].invoke
52   - Dir["#{File.dirname(__FILE__)}/pkg/*.gem"].each do |pkg|
53   - system "gem push #{pkg}"
54   - end
55   - end
56   -end
57   -
58   -desc "Validate the gemspec"
59   -task :gemspec do
60   - gemspec.validate
61   -end
  1 +require 'bundler/gem_tasks'
62 2
63 3 # DELETE AFTER USING
64 4 desc "Rename project"
2  gem_template.gemspec
@@ -18,4 +18,6 @@ Gem::Specification.new do |s|
18 18 s.files = `cd #{root} && git ls-files`.split("\n")
19 19 s.require_paths = %w(lib)
20 20 s.test_files = `cd #{root} && git ls-files -- {features,test,spec}/*`.split("\n")
  21 +
  22 + s.add_development_dependency "rspec", "~> 1.0"
21 23 end
5 lib/gem_template.rb
... ... @@ -1,8 +1,3 @@
1   -require "rubygems"
2   -require "bundler"
3   -
4   -Bundler.require(:default)
5   -
6 1 $:.unshift File.dirname(__FILE__)
7 2
8 3 module GemTemplate
2  spec/spec_helper.rb
... ... @@ -1,7 +1,7 @@
1 1 require "pp"
2 2 require "bundler"
3 3
4   -Bundler.require(:spec)
  4 +Bundler.require(:development)
5 5
6 6 $root = File.expand_path('../../', __FILE__)
7 7

0 comments on commit 5e2dd99

Please sign in to comment.
Something went wrong with that request. Please try again.