about summary refs log tree commit homepage
diff options
context:
space:
mode:
authorzedshaw <zedshaw@19e92222-5c0b-0410-8929-a290d50e31e9>2006-03-09 03:05:11 +0000
committerzedshaw <zedshaw@19e92222-5c0b-0410-8929-a290d50e31e9>2006-03-09 03:05:11 +0000
commit97502ebea97890d3b49427ba7381622e2bb4fe5e (patch)
tree263a80af02977b8bd14231ee25f112c8bd92ad97
parent5bf3bca4955c64ad5d2f03c0b717f8924e234830 (diff)
downloadunicorn-97502ebea97890d3b49427ba7381622e2bb4fe5e.tar.gz
git-svn-id: svn+ssh://rubyforge.org/var/svn/mongrel/trunk@88 19e92222-5c0b-0410-8929-a290d50e31e9
-rw-r--r--bin/mongrel_rails5
-rw-r--r--lib/mongrel.rb1
-rw-r--r--lib/mongrel/command.rb3
-rw-r--r--lib/mongrel/init.rb (renamed from lib/mongrel/plugins.rb)2
-rw-r--r--lib/mongrel/rails.rb1
-rw-r--r--projects/gem_plugin/Rakefile4
-rw-r--r--projects/gem_plugin/lib/gem_plugin.rb2
7 files changed, 8 insertions, 10 deletions
diff --git a/bin/mongrel_rails b/bin/mongrel_rails
index bc2aac4..eb04b86 100644
--- a/bin/mongrel_rails
+++ b/bin/mongrel_rails
@@ -1,7 +1,6 @@
 require 'rubygems'
-require 'mongrel/rails'
 require 'yaml'
-
+require 'mongrel'
 
 
 class Start < GemPlugin::Plugin "/commands"
@@ -78,7 +77,7 @@ class Start < GemPlugin::Plugin "/commands"
     ENV['RAILS_ENV'] = @environment
     require 'config/environment'
     require 'dispatcher'
-    require 'cgi'
+    require 'mongrel/rails'
 
     # configure the rails handler
     rails = RailsHandler.new(@docroot, load_mime_map)
diff --git a/lib/mongrel.rb b/lib/mongrel.rb
index f135ca3..fa43942 100644
--- a/lib/mongrel.rb
+++ b/lib/mongrel.rb
@@ -5,7 +5,6 @@ require 'stringio'
 require 'mongrel/cgi'
 require 'mongrel/handlers'
 require 'mongrel/command'
-require 'mongrel/plugins'
 require 'timeout'
 
 # Mongrel module containing all of the classes (include C extensions) for running
diff --git a/lib/mongrel/command.rb b/lib/mongrel/command.rb
index be25f8f..e65f8cf 100644
--- a/lib/mongrel/command.rb
+++ b/lib/mongrel/command.rb
@@ -1,6 +1,7 @@
+require 'rubygems'
 require 'singleton'
 require 'optparse'
-require 'mongrel/plugins'
+require 'gem_plugin'
 
 module Mongrel
 
diff --git a/lib/mongrel/plugins.rb b/lib/mongrel/init.rb
index 670d1db..eaea549 100644
--- a/lib/mongrel/plugins.rb
+++ b/lib/mongrel/init.rb
@@ -1,5 +1,5 @@
 require 'rubygems'
-require_gem 'gem_plugin'
+require 'gem_plugin'
 
 # file is just a stub that makes sure the mongrel_plugins gem is loaded and ready
 
diff --git a/lib/mongrel/rails.rb b/lib/mongrel/rails.rb
index ecff187..3b99194 100644
--- a/lib/mongrel/rails.rb
+++ b/lib/mongrel/rails.rb
@@ -1,7 +1,6 @@
 require 'mongrel'
 require 'cgi'
 
-
 # Implements a handler that can run Rails and serve files out of the
 # Rails application's public directory.  This lets you run your Rails
 # application with Mongrel during development and testing, then use it
diff --git a/projects/gem_plugin/Rakefile b/projects/gem_plugin/Rakefile
index bc53ef1..b5a278e 100644
--- a/projects/gem_plugin/Rakefile
+++ b/projects/gem_plugin/Rakefile
@@ -15,7 +15,7 @@ setup_rdoc ['README', 'LICENSE', 'COPYING', 'lib/**/*.rb', 'doc/**/*.rdoc']
 desc "Does a full compile, test run"
 task :default => [:test, :package]
 
-version="0.1"
+version="0.2"
 summary = "A plugin system based only on rubygems"
 test_file = "test/test_plugins.rb"
 author="Zed A. Shaw"
@@ -23,7 +23,7 @@ name="gem_plugin"
 scripts=[]
 
 setup_gem(name, version,  author, summary, scripts, test_file) do |spec|
-  spec.autorequire = "gem_plugin"
+  spec.description = summary
 end
 
 task :gem_test => [:package] do
diff --git a/projects/gem_plugin/lib/gem_plugin.rb b/projects/gem_plugin/lib/gem_plugin.rb
index 3b537f4..41f3142 100644
--- a/projects/gem_plugin/lib/gem_plugin.rb
+++ b/projects/gem_plugin/lib/gem_plugin.rb
@@ -110,7 +110,7 @@ module GemPlugin
         # makes them false so we'll skip this gem if any excludes are found
         if (check.select {|name,test| !test}).length == 0
           # looks like no needs were set to false, so it's good
-          require_gem gem.name
+          require "#{gem.name}/init"
           @loaded_gems << gem.name
         end