Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

A bunch of clean ups.

- Removed TODO.
- Updated Gemfile and Gemfile.lock.
- Removed cumbersome rake tasks (bundler has gem packaging built-in).
- Added a VERSION constant.
- Refined the gemspec.
- Prep for 0.2.0 release.
  • Loading branch information...
commit 4427a27f9cc1908b1e339b9dcc517469a66bab5a 1 parent 354e1de
Fred Wu authored
View
9 Gemfile
@@ -2,8 +2,7 @@ source 'http://rubygems.org'
gemspec
-gem "ruby-debug", :platforms => :mri_18
-gem "ruby-debug19", :platforms => :mri_19
-
-gem "autotest", ">= 0"
-gem "growl-glue", ">= 0"
+group :development do
+ gem "ruby-debug", :platforms => :mri_18
+ gem "ruby-debug19", :platforms => :mri_19
+end
View
32 Gemfile.lock
@@ -1,35 +1,33 @@
PATH
remote: .
specs:
- rails_config (0.1.7)
+ rails_config (0.2.0)
activesupport (~> 3.0)
GEM
remote: http://rubygems.org/
specs:
- activesupport (3.0.0)
+ activesupport (3.0.2)
archive-tar-minitar (0.5.2)
- autotest (4.3.2)
- columnize (0.3.1)
+ autotest (4.4.3)
+ columnize (0.3.2)
diff-lcs (1.1.2)
growl-glue (1.0.7)
linecache (0.43)
linecache19 (0.5.11)
ruby_core_source (>= 0.1.4)
- rspec (2.0.0)
- rspec-core (= 2.0.0)
- rspec-expectations (= 2.0.0)
- rspec-mocks (= 2.0.0)
- rspec-core (2.0.0)
- rspec-expectations (2.0.0)
- diff-lcs (>= 1.1.2)
- rspec-mocks (2.0.0)
- rspec-core (= 2.0.0)
- rspec-expectations (= 2.0.0)
- ruby-debug (0.10.3)
+ rspec (2.1.0)
+ rspec-core (~> 2.1.0)
+ rspec-expectations (~> 2.1.0)
+ rspec-mocks (~> 2.1.0)
+ rspec-core (2.1.0)
+ rspec-expectations (2.1.0)
+ diff-lcs (~> 1.1.2)
+ rspec-mocks (2.1.0)
+ ruby-debug (0.10.4)
columnize (>= 0.1)
- ruby-debug-base (~> 0.10.3.0)
- ruby-debug-base (0.10.3)
+ ruby-debug-base (~> 0.10.4.0)
+ ruby-debug-base (0.10.4)
linecache (>= 0.3)
ruby-debug-base19 (0.11.24)
columnize (>= 0.3.1)
View
27 Rakefile
@@ -1,24 +1,10 @@
-require "bundler"
-Bundler.setup
-
-require 'rake'
-require 'rake/gempackagetask'
-
-gemspec = eval(File.read('rails_config.gemspec'))
-Rake::GemPackageTask.new(gemspec) do |pkg|
- pkg.gem_spec = gemspec
-end
-
-desc "build the gem and release it to rubygems.org"
-task :release => :gem do
- puts "Tagging #{gemspec.version}..."
- system "git tag -a #{gemspec.version} -m 'Tagging #{gemspec.version}'"
- puts "Pushing to Github..."
- system "git push --tags"
- puts "Pushing to rubygems.org..."
- system "gem push pkg/#{gemspec.name}-#{gemspec.version}.gem"
+begin
+ require "bundler"
+ Bundler::GemHelper.install_tasks
+rescue Exception => e
end
+require "rake"
require "rspec"
require "rspec/core/rake_task"
@@ -34,10 +20,9 @@ end
require "rake/rdoctask"
Rake::RDocTask.new do |rdoc|
rdoc.rdoc_dir = "rdoc"
- rdoc.title = "Rails Config #{gemspec.version}"
+ rdoc.title = "Rails Config #{RailsConfig::VERSION}"
rdoc.rdoc_files.include("README*")
rdoc.rdoc_files.include("lib/**/*.rb")
end
-
task :default => :spec
View
8 TODO
@@ -1,8 +0,0 @@
-- Change part of the install generator to `rails_config:override` that creates an config/rails_config.rb initializer and disables the default initialzer
-
-DONE:
-- Add a Rails before_filter that triggers Settings.reload! for each development request
-- Add generator `rails_config:install` to create the default setting files
-- Allow user to customize the name of the global setting object (Settings)
-- Abstract OpenStruct to RailsConfig::Options
-- Add ability to define multiple sources (Start with YAMLSource)
View
3  lib/rails_config/version.rb
@@ -0,0 +1,3 @@
+module RailsConfig
+ VERSION = "0.2.0"
+end
View
46 rails_config.gemspec
@@ -1,34 +1,24 @@
-Gem::Specification.new do |s|
- s.name = "rails_config"
- s.version = "0.1.7"
-
- s.authors = ["Jacques Crocker", "Fred Wu"]
- s.summary = "Provides a Settings helper for rails3 that reads from config/settings.yml"
- s.description = "Easy to use Settings helper that loads its data in from config/settings.yml. Handles adding multiple sources, and easy reloading."
- s.email = ["railsjedi@gmail.com", "ifredwu@gmail.com"]
- s.homepage = "http://github.com/railsjedi/rails_config"
-
- s.require_paths = ["lib"]
- s.files = Dir['lib/**/*',
- 'spec/**/*',
- 'rails_config.gemspec',
- 'Gemfile',
- 'Gemfile.lock',
- 'LICENSE',
- 'Rakefile',
- 'README.md',
- 'TODO']
+require File.dirname(__FILE__) + "/lib/rails_config/version"
- s.test_files = Dir['spec/**/*']
- s.rdoc_options = ["--charset=UTF-8"]
- s.extra_rdoc_files = [
- "LICENSE",
- "README.md",
- "TODO"
- ]
+Gem::Specification.new do |s|
+ s.name = "rails_config"
+ s.version = RailsConfig::VERSION
+ s.date = Date.today.to_s
+ s.authors = ["Jacques Crocker", "Fred Wu"]
+ s.email = ["railsjedi@gmail.com", "ifredwu@gmail.com"]
+ s.summary = "Provides a Settings helper for rails3 that reads from config/settings.yml"
+ s.description = "Easy to use Settings helper that loads its data in from config/settings.yml. Handles adding multiple sources, and easy reloading."
+ s.homepage = "http://github.com/railsjedi/rails_config"
+ s.extra_rdoc_files = ["README.md"]
+ s.rdoc_options = ["--charset=UTF-8"]
+ s.require_paths = ["lib"]
+ 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.add_runtime_dependency "activesupport", "~> 3.0"
s.add_development_dependency "rspec", "~> 2.0"
-
+ s.add_development_dependency "autotest", ">= 0"
+ s.add_development_dependency "growl-glue", ">= 0"
end
Please sign in to comment.
Something went wrong with that request. Please try again.