Permalink
Browse files

clean up gemspec

  • Loading branch information...
1 parent 9b05df0 commit 2e2fc501123ad87dad4dcdb159fe04380832c4c0 @rkh rkh committed Jun 5, 2011
Showing with 21 additions and 144 deletions.
  1. +0 −21 Rakefile
  2. +8 −4 lib/sinatra/base.rb
  3. +3 −0 lib/sinatra/version.rb
  4. +10 −119 sinatra.gemspec
View
@@ -147,27 +147,6 @@ if defined?(Gem)
SH
end
- task 'sinatra.gemspec' => FileList['{lib,test,compat}/**','Rakefile','CHANGES','*.rdoc'] do |f|
- # read spec file and split out manifest section
- spec = File.read(f.name)
- head, manifest, tail = spec.split(" # = MANIFEST =\n")
- # replace version
- head.sub!(/\.version = '.*'/, ".version = '#{source_version}'")
- # determine file list from git ls-files
- files = `git ls-files`.
- split("\n").
- sort.
- reject{ |file| file =~ /^\./ }.
- reject { |file| file =~ /^doc/ }.
- map{ |file| " #{file}" }.
- join("\n")
- # piece file back together and write...
- manifest = " s.files = %w[\n#{files}\n ]\n"
- spec = [head,manifest,tail].join(" # = MANIFEST =\n")
- File.open(f.name, 'w') { |io| io.write(spec) }
- puts "updated #{f.name}"
- end
-
task 'release' => ['test', package('.gem')] do
sh <<-SH
gem install #{package('.gem')} --local &&
View
@@ -1,13 +1,17 @@
+# external dependencies
+require 'rack'
+require 'tilt'
+
+# stdlib dependencies
require 'thread'
require 'time'
require 'uri'
-require 'rack'
+
+# other files we need
require 'sinatra/showexceptions'
-require 'tilt'
+require 'sinatra/version'
module Sinatra
- VERSION = '1.3.0'
-
# The request object. See Rack::Request for more info:
# http://rack.rubyforge.org/doc/classes/Rack/Request.html
class Request < Rack::Request
View
@@ -0,0 +1,3 @@
+module Sinatra
+ VERSION = '1.3.0'
+end
View
@@ -1,125 +1,16 @@
-Gem::Specification.new do |s|
- s.name = 'sinatra'
- s.version = '1.3.0'
-
- s.description = "Classy web-development dressed in a DSL"
- s.summary = "Classy web-development dressed in a DSL"
-
- s.authors = ["Blake Mizerany", "Ryan Tomayko", "Simon Rozet", "Konstantin Haase"]
- s.email = "sinatrarb@googlegroups.com"
-
- # = MANIFEST =
- s.files = %w[
- AUTHORS
- CHANGES
- Gemfile
- LICENSE
- README.de.rdoc
- README.es.rdoc
- README.fr.rdoc
- README.hu.rdoc
- README.jp.rdoc
- README.pt-br.rdoc
- README.pt-pt.rdoc
- README.rdoc
- README.ru.rdoc
- README.zh.rdoc
- Rakefile
- lib/sinatra.rb
- lib/sinatra/base.rb
- lib/sinatra/images/404.png
- lib/sinatra/images/500.png
- lib/sinatra/main.rb
- lib/sinatra/showexceptions.rb
- sinatra.gemspec
- test/base_test.rb
- test/builder_test.rb
- test/coffee_test.rb
- test/contest.rb
- test/creole_test.rb
- test/delegator_test.rb
- test/encoding_test.rb
- test/erb_test.rb
- test/extensions_test.rb
- test/filter_test.rb
- test/haml_test.rb
- test/helper.rb
- test/helpers_test.rb
- test/less_test.rb
- test/liquid_test.rb
- test/mapped_error_test.rb
- test/markaby_test.rb
- test/markdown_test.rb
- test/middleware_test.rb
- test/nokogiri_test.rb
- test/public/favicon.ico
- test/radius_test.rb
- test/rdoc_test.rb
- test/readme_test.rb
- test/request_test.rb
- test/response_test.rb
- test/result_test.rb
- test/route_added_hook_test.rb
- test/routing_test.rb
- test/sass_test.rb
- test/scss_test.rb
- test/server_test.rb
- test/settings_test.rb
- test/sinatra_test.rb
- test/slim_test.rb
- test/static_test.rb
- test/templates_test.rb
- test/textile_test.rb
- test/views/a/in_a.str
- test/views/ascii.erb
- test/views/b/in_b.str
- test/views/calc.html.erb
- test/views/error.builder
- test/views/error.erb
- test/views/error.haml
- test/views/error.sass
- test/views/explicitly_nested.str
- test/views/foo/hello.test
- test/views/hello.builder
- test/views/hello.coffee
- test/views/hello.creole
- test/views/hello.erb
- test/views/hello.haml
- test/views/hello.less
- test/views/hello.liquid
- test/views/hello.mab
- test/views/hello.md
- test/views/hello.nokogiri
- test/views/hello.radius
- test/views/hello.rdoc
- test/views/hello.sass
- test/views/hello.scss
- test/views/hello.slim
- test/views/hello.str
- test/views/hello.test
- test/views/hello.textile
- test/views/layout2.builder
- test/views/layout2.erb
- test/views/layout2.haml
- test/views/layout2.liquid
- test/views/layout2.mab
- test/views/layout2.nokogiri
- test/views/layout2.radius
- test/views/layout2.slim
- test/views/layout2.str
- test/views/layout2.test
- test/views/nested.str
- test/views/utf8.erb
- ]
- # = MANIFEST =
-
- s.add_dependency 'rack', '~> 1.3'
- s.add_dependency 'tilt', '~> 1.3'
- s.add_development_dependency 'shotgun', '~> 0.6'
+load './lib/sinatra/version.rb'
+Gem::Specification.new 'sinatra', Sinatra::VERSION do |s|
+ s.description = "Classy web-development dressed in a DSL"
+ s.summary = s.description
+ s.authors = ["Blake Mizerany", "Ryan Tomayko", "Simon Rozet", "Konstantin Haase"]
+ s.email = "sinatrarb@googlegroups.com"
+ s.files = `git ls-files`.split("\n")
s.test_files = s.files.select { |p| p =~ /^test\/.*_test.rb/ }
s.extra_rdoc_files = s.files.select { |p| p =~ /^README/ } << 'LICENSE'
s.homepage = "http://sinatra.rubyforge.org"
s.rdoc_options = %w[--line-numbers --inline-source --title Sinatra --main README.rdoc]
- s.rubyforge_project = 'sinatra'
+
+ s.add_dependency 'rack', '~> 1.3'
+ s.add_dependency 'tilt', '~> 1.3'
end

0 comments on commit 2e2fc50

Please sign in to comment.