<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>HISTORY</filename>
    </added>
    <added>
      <filename>data/.git-darcs-dir</filename>
    </added>
    <added>
      <filename>data/sources/.git-darcs-dir</filename>
    </added>
    <added>
      <filename>data/sources/lib/.git-darcs-dir</filename>
    </added>
    <added>
      <filename>data/sources/lib/sources.rb</filename>
    </added>
    <added>
      <filename>data/sources/sources.gemspec</filename>
    </added>
    <added>
      <filename>gemspec.rb</filename>
    </added>
    <added>
      <filename>lib/configuration.rb</filename>
    </added>
    <added>
      <filename>lib/stickler/configuration.rb</filename>
    </added>
    <added>
      <filename>tasks/config.rb</filename>
    </added>
    <added>
      <filename>tasks/utils.rb</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -1,6 +1,6 @@
-stickler is copyrighted free software by Jeremy Hinegardner &lt;jeremy@hinegardner.org&gt;.
-You can redistribute it and/or modify it under either the terms of the GPL
-(see COPYING file), or the conditions below:
+Stickler is copyrighted free software by Jeremy Hinegardner 
+&lt;jeremy at hinegardner dot org&gt;.  You can redistribute it and/or modify it under
+either the terms of the GPL (see COPYING file), or the conditions below:
 
   1. You may make and give away verbatim copies of the source form of the
      software without restriction, provided that you duplicate all of the</diff>
      <filename>LICENSE</filename>
    </modified>
    <modified>
      <diff>@@ -1,15 +1,48 @@
-== stickler
+= Stickler
 
-* Homepage
-* rubyforge project
-* email
+* Homepage[http://copiousfreetime.rubyforge.org/stickler/]
+* {Rubyforge Project}[http://rubyforge.org/projects/copiousfreetime/]
+* email jeremy at hinegardner dot org 
 
 == DESCRIPTION
 
+Stickler is a tool to organize and maintain an internal gem distribution server.
+
+At times it is useful to have complete control over the availability of the gems
+for you testing, staging and production environments.  In these cases you
+probably do not want to accidentally type 'gem update' and get a new untested
+version of a gem installed on your machines.  This is where Stickler helps.
+
+Configure stickler with the the names and versions of the gems you require for
+your deployment and it will organize and setup a gem server to serve up only
+those gems.
+
+== INSTALLATION
+
+Install as a gem:
+
+   sudo gem install stickler
+
+Or Get it from RubyForge[http://rubyforge.org/projects/copiousfreetime/] 
+
 == FEATURES
 
+* Serve up a custom collection of gems for your own use.
+* Generation of a custom 'sources' gem to have your rubygems installations point
+  to your custom gem server.
+* Tracking of the gems you care about and notification when a new version of those
+  are released on rubyforge.
+* Integrates with your internal build system so your internal gems can be
+  deployed to the stickler gem server
+
 == SYNOPSIS
 
 == CREDITS
 
+* {The Rubygems Team}[http://rubyforge.org/projects/rubygems/]
+
 == LICENSE
+
+Copyright (c) 2008 Jeremy Hinegardner
+All rights reserved. Licensed under the same terms as Ruby.  No warranty is
+provided.  See LICENSE and COPYING for details.</diff>
      <filename>README</filename>
    </modified>
    <modified>
      <diff>@@ -1,14 +1,46 @@
-# make sure our project's ./lib directory is added to the ruby search path
-$: &lt;&lt; File.join(File.dirname(__FILE__),&quot;lib&quot;)
+#--
+# Copyright (c) 2008 Jeremy Hinegardner
+# All rights reserved.  Licensed under the same terms as Ruby.  No warranty is
+# provided.  See LICENSE and COPYING for details.
+#++
 
+#-------------------------------------------------------------------------------
+# make sure our project's top level directory and the lib directory are added to
+# the ruby search path.
+#-------------------------------------------------------------------------------
+$: &lt;&lt; File.expand_path(File.join(File.dirname(__FILE__),&quot;lib&quot;))
+$: &lt;&lt; File.expand_path(File.dirname(__FILE__))
+
+#-------------------------------------------------------------------------------
+# load the global project configuration and add in the top level clean and
+# clobber tasks so that other tasks can utilize those constants if necessary
+#-------------------------------------------------------------------------------
 require 'rubygems'
-require 'rake/gempackagetask'
+require 'tasks/config.rb'
 require 'rake/clean'
-require 'rake/rdoctask'
-require 'rake/contrib/sshpublisher'
-
-require 'stickler'
 
-load 'tasks/setup.rb'
+#-------------------------------------------------------------------------------
+# load up all the project tasks and setup the default task to be the
+# test:default task.
+#-------------------------------------------------------------------------------
+Configuration.for(&quot;packaging&quot;).files.tasks.each do |tasklib|
+  import tasklib
+end
+task :default =&gt; 'test:default'
 
+#-------------------------------------------------------------------------------
+# Finalize the loading of all pending imports and update the top level clobber
+# task to depend on all possible sub-level tasks that have a name like
+# ':clobber'  in other namespaces.  This allows us to say:
+#
+#   rake clobber
+#
+# and it will get everything.
+#-------------------------------------------------------------------------------
+Rake.application.load_imports
+Rake.application.tasks.each do |t| 
+  if t.name =~ /:clobber/ then
+    task :clobber =&gt; [t.name] 
+  end
+end
 </diff>
      <filename>Rakefile</filename>
    </modified>
    <modified>
      <diff>@@ -1,12 +1,43 @@
 #!/usr/bin/env ruby
 
-begin
-    require 'stickler'
-rescue LoadError 
-    path = File.expand_path(File.join(File.dirname(__FILE__),&quot;..&quot;,&quot;lib&quot;))
-    raise if $:.include?(path)
-    $: &lt;&lt; path
-    retry
+require 'rubygems'
+
+gem = ARGV.shift
+ver = ARGV.shift || Gem::Requirement.default
+
+require 'rubygems/source_info_cache'
+require 'rubygems/dependency_list'
+
+original_dep =  Gem::Dependency.new( gem, ver )
+
+# actually search through and find the ones for this platform
+def spec_from_dependency(dep)
+  spec_and_source = Gem::SourceInfoCache.search_with_source(dep).reverse.first 
+  spec = spec_and_source.first
+  return spec
+end
+
+dep_stack = []
+dep_stack.push(spec_from_dependency(original_dep))
+dep_list = Gem::DependencyList.new
+seen = {}
+
+until dep_stack.empty? 
+    spec = dep_stack.pop
+    next if spec.nil? or seen[spec.name]
+    puts &quot;---&gt; #{spec.full_name}&quot;
+    seen[spec.name] = true
+
+    spec.dependencies.each do |dep|
+        d = spec_from_dependency(dep)
+        next if seen[d.name]
+        puts &quot;&lt;--- #{d.full_name}&quot;
+        dep_stack.push(d)
+    end
+    dep_list.add spec
 end
 
-puts &quot;I am the killer app stickler at version #{Stickler::VERSION}!&quot;
+
+dep_list.dependency_order.reverse.each do |s|
+    puts &quot;Install #{s.full_name}&quot;
+end</diff>
      <filename>bin/stickler</filename>
    </modified>
    <modified>
      <diff>@@ -1,25 +1,23 @@
+#--
+# Copyright (c) 2008 Jeremy Hinegardner
+# All rights reserved.  Licensed under the same terms as Ruby.  No warranty is
+# provided.  See LICENSE and COPYING for details.
+#++
+
 module Stickler
-    
-    ROOT_DIR        = File.expand_path(File.join(File.dirname(__FILE__),&quot;..&quot;))
-    LIB_DIR         = File.join(ROOT_DIR,&quot;lib&quot;).freeze
-    RESOURCE_DIR    = File.join(ROOT_DIR,&quot;resources&quot;).freeze
 
-    # 
-    # Utility method to require all files ending in .rb in the directory
-    # with the same name as this file minus .rb
-    #
-    def require_all_libs_relative_to(fname)
-        prepend   = File.basename(fname,&quot;.rb&quot;)
-        search_me = File.join(File.dirname(fname),prepend)
-     
-        Dir.entries(search_me).each do |rb|
-            if File.extname(rb) == &quot;.rb&quot; then
-                require &quot;#{prepend}/#{File.basename(rb,&quot;.rb&quot;)}&quot;
-            end
-        end
-    end 
-    module_function :require_all_libs_relative_to
+  # recursively descend the directory with the same name as this file and do a
+  # require 'stickler/path/to/file'
+  #
+  def self.require_all_libs_relative_to_me
+    remove_parent = File.dirname(File.expand_path(__FILE__)) + File::SEPARATOR
+    descend_dir   = File.join(remove_parent,File.basename(__FILE__, &quot;.rb&quot;))
 
+    Dir.glob(&quot;#{descend_dir}/**/*.rb&quot;).each do |rb|
+      lib = rb.gsub(remove_parent,'')
+      require lib
+    end
+  end
 end
 
-Stickler.require_all_libs_relative_to(__FILE__)
+Stickler.require_all_libs_relative_to_me</diff>
      <filename>lib/stickler.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,18 +1,32 @@
+#--
+# Copyright (c) 2008 Jeremy Hinegardner
+# All rights reserved.  Licensed under the same terms as Ruby.  No warranty is
+# provided.  See LICENSE and COPYING for details.
+#++
+#
 module Stickler
-    class Version
-        MAJOR   = 0
-        MINOR   = 0
-        BUILD   = 1
 
-        class &lt;&lt; self
-            def to_a
-                [MAJOR, MINOR, BUILD]
-            end
+  # Version access in every possibly way that people might want to get it.
+  #
+  module Version
 
-            def to_s
-                to_a.join(&quot;.&quot;)
-            end
-        end
+    MAJOR = 0
+    MINOR = 0
+    BUILD = 1
+
+    def self.to_ary
+      [MAJOR, MINOR, BUILD]
+    end
+
+    def self.to_s
+      self.to_ary.join(&quot;.&quot;)
     end
-    VERSION = Version.to_s
+
+    def self.to_hash
+      { :major =&gt; MAJOR, :minor =&gt; MINOR, :build =&gt; BUILD }
+    end
+    
+  end
+
+  VERSION = Version.to_s
 end</diff>
      <filename>lib/stickler/version.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,32 +1,37 @@
 #-----------------------------------------------------------------------
 # Distribution and Packaging
 #-----------------------------------------------------------------------
-namespace :dist do
+require 'tasks/config'
 
-    GEM_SPEC = eval(Stickler::SPEC.to_ruby)
+# only do this task if the appropriate section from the configuration exists
+if pkg_config= Configuration.for_if_exist(&quot;packaging&quot;) then
 
-    Rake::GemPackageTask.new(GEM_SPEC) do |pkg|
-        pkg.need_tar = Stickler::SPEC.need_tar
-        pkg.need_zip = Stickler::SPEC.need_zip
+  require 'gemspec'
+  require 'rake/gempackagetask'
+
+  namespace :dist do
+    Rake::GemPackageTask.new(Stickler::GEM_SPEC) do |pkg|
+      pkg.need_tar = pkg_config.formats.tgz
+      pkg.need_zip = pkg_config.formats.zip
     end
 
     desc &quot;Install as a gem&quot;
     task :install =&gt; [:clobber, :package] do
-        sh &quot;sudo gem install pkg/#{Stickler::SPEC.full_name}.gem&quot;
+      sh &quot;sudo gem install -y pkg/#{Stickler::SPEC.full_name}.gem&quot;
     end
 
-    # uninstall the gem and all executables
     desc &quot;Uninstall gem&quot;
     task :uninstall do 
-        sh &quot;sudo gem uninstall #{Stickler::SPEC.name} -x&quot;
+      sh &quot;sudo gem uninstall -i #{Stickler::SPEC.name} -x&quot;
     end
 
     desc &quot;dump gemspec&quot;
     task :gemspec do
-        puts Stickler::SPEC.to_ruby
+      puts Stickler::GEM_SPEC
     end
 
     desc &quot;reinstall gem&quot;
-    task :reinstall =&gt; [:uninstall, :install]
+    task :reinstall =&gt; [:uninstall, :repackage, :install]
 
-end
\ No newline at end of file
+  end
+end</diff>
      <filename>tasks/distribution.rake</filename>
    </modified>
    <modified>
      <diff>@@ -2,24 +2,32 @@
 # Documentation
 #-----------------------------------------------------------------------
 
-namespace :doc do
-    
+require 'tasks/config'
+if rdoc_config = Configuration.for('rdoc') then
+
+  namespace :doc do
+
+    require 'rake/rdoctask'
+
     # generating documentation locally
     Rake::RDocTask.new do |rdoc|
-        rdoc.rdoc_dir   = Stickler::SPEC.local_rdoc_dir
-        rdoc.options    = Stickler::SPEC.rdoc_options 
-        rdoc.rdoc_files = Stickler::SPEC.rdoc_files
+      rdoc.rdoc_dir   = rdoc_config.output_dir
+      rdoc.options    = rdoc_config.options
+      rdoc.rdoc_files = rdoc_config.files
+      rdoc.title      = rdoc_config.title
+      rdoc.main       = rdoc_config.main
     end
 
-    desc &quot;Deploy the RDoc documentation to #{Stickler::SPEC.remote_rdoc_location}&quot;
-    task :deploy =&gt; :rerdoc do
-        sh &quot;rsync -zav --delete #{Stickler::SPEC.local_rdoc_dir}/ #{Stickler::SPEC.remote_rdoc_location}&quot;
-    end
+    # desc &quot;Deploy the RDoc documentation to #{Stickler::SPEC.remote_rdoc_location}&quot;
+    # task :deploy =&gt; :rerdoc do
+      # sh &quot;rsync -zav --delete #{Stickler::SPEC.local_rdoc_dir}/ #{Stickler::SPEC.remote_rdoc_location}&quot;
+    # end
 
-    if HAVE_HEEL then
-        desc &quot;View the RDoc documentation locally&quot;
-        task :view =&gt; :rdoc do
-            sh &quot;heel --root  #{Stickler::SPEC.local_rdoc_dir}&quot;
-        end
-    end
-end
\ No newline at end of file
+    # if HAVE_HEEL then
+      # desc &quot;View the RDoc documentation locally&quot;
+      # task :view =&gt; :rdoc do
+        # sh &quot;heel --root  #{Stickler::SPEC.local_rdoc_dir}&quot;
+      # end
+    # end
+  end
+end</diff>
      <filename>tasks/documentation.rake</filename>
    </modified>
    <modified>
      <diff>@@ -1,24 +1,32 @@
-require 'spec/rake/spectask'
-
-#-----------------------------------------------------------------------
-# Testing - this is either test or spec, include the appropriate one
-#-----------------------------------------------------------------------
-namespace :test do
+require 'tasks/config'
+if spec_config = Configuration.for_if_exist('test') then
 
+  namespace :test do
+  
     task :default =&gt; :spec
-
+    
+    require 'spec/rake/spectask'
     Spec::Rake::SpecTask.new do |r| 
+      r.ruby_opts   = spec_config.ruby_opts
+      r.libs        = [ Stickler::Configuration.lib_path, 
+                      Stickler::Configuration.root_dir ]
+      r.spec_files  = spec_config.files
+      r.spec_opts   = spec_config.options
+
+      if rcov_config = Configuration.for_if_exist('rcov') then
         r.rcov      = true
-        r.rcov_dir  = Stickler::SPEC.local_coverage_dir
-        r.libs      = Stickler::SPEC.require_paths
-        r.spec_opts = %w(--format specdoc --color)
-    end
+        r.rcov_dir  = rcov_config.output_dir
+        r.rcov_opts = rcov_config.rcov_opts
+      end
 
-    if HAVE_HEEL then
-        desc &quot;View the code coverage report locally&quot;
-        task :coverage =&gt; [:spec] do
-            sh &quot;heel --root #{Stickler::SPEC.local_coverage_dir}&quot;
-        end 
     end
-    
+  end
+
+  #if HAVE_HEEL then
+  #desc &quot;View the code coverage report locally&quot;
+  #task :coverage =&gt; [:spec] do
+  #sh &quot;heel --root #{Stickler::SPEC.local_coverage_dir}&quot;
+  #end 
+  #end
+
 end</diff>
      <filename>tasks/rspec.rake</filename>
    </modified>
    <modified>
      <diff>@@ -1,43 +1,46 @@
-if HAVE_RUBYFORGE then
-    require 'rubyforge'
-    
-    #-----------------------------------------------------------------------
-    # Rubyforge additions to the task library
-    #-----------------------------------------------------------------------
-    namespace :dist do
-        desc &quot;Release files to rubyforge&quot;
-        task :rubyforge =&gt; [:clean, :package] do
+require 'tasks/config'
+if rf_conf = Configuration.for_if_exist('rubyforge') then
+  #-----------------------------------------------------------------------
+  # Rubyforge additions to the task library
+  #-----------------------------------------------------------------------
+  require 'rubyforge'
+  
+  prof_conf = Configuration.for('project')
 
-            rubyforge = RubyForge.new
+  namespace :dist do
+    desc &quot;Release files to rubyforge&quot;
+    task :rubyforge =&gt; [:clean, :package] do
 
-            # make sure this release doesn't already exist
-            releases = rubyforge.autoconfig['release_ids']
-            if releases.has_key?(Stickler::SPEC.name) and releases[Stickler::SPEC.name][Stickler::VERSION] then
-                abort(&quot;Release #{Stickler::VERSION} already exists! Unable to release.&quot;)
-            end
+      rubyforge = ::RubyForge.new
 
-            config = rubyforge.userconfig
-            config[&quot;release_notes&quot;]     = Stickler::SPEC.description
-            config[&quot;release_changes&quot;]   = last_changeset
-            config[&quot;Prefomatted&quot;]       = true
+      # make sure this release doesn't already exist
+      releases = rubyforge.autoconfig['release_ids']
+      if releases.has_key?(prof_conf.name) and releases[prof_conf.name][Stickler::VERSION] then
+        abort(&quot;Release #{Stickler::VERSION} already exists! Unable to release.&quot;)
+      end
 
-            puts &quot;Uploading to rubyforge...&quot;
-            files = FileList[File.join(&quot;pkg&quot;,&quot;#{Stickler::SPEC.name}-#{Stickler::VERSION}*.*&quot;)].to_a
-            rubyforge.login
-            rubyforge.add_release(Stickler::SPEC.rubyforge_project, Stickler::SPEC.name, Stickler::VERSION, *files)
-            puts &quot;done.&quot;
-            end
-    end
+      config = rubyforge.userconfig
+      config[&quot;release_notes&quot;]     = prof_conf.description
+      config[&quot;release_changes&quot;]   = Utils.release_notes_from(proj_conf.history)[Stickler::VERSION]
+      config[&quot;Prefomatted&quot;]       = true
 
-    namespace :announce do
-        desc &quot;Post news of #{Stickler::SPEC.name} to #{Stickler::SPEC.rubyforge_project} on rubyforge&quot;
-        task :rubyforge do
-            subject, title, body, urls = announcement
-            rubyforge = RubyForge.new
-            rubyforge.login
-            rubyforge.post_news(Stickler::SPEC.rubyforge_project, subject, &quot;#{title}\n\n#{urls}\n\n#{body}&quot;)
-            puts &quot;Posted to rubyforge&quot;
-        end
+      puts &quot;Uploading to rubyforge...&quot;
+      files = FileList[File.join(&quot;pkg&quot;,&quot;#{prof_conf.name}-#{Stickler::VERSION}*.*&quot;)].to_a
+      rubyforge.login
+      rubyforge.add_release(rf_conf.project, prof_conf.name, Stickler::VERSION, *files)
+      puts &quot;done.&quot;
+    end
+  end
 
+  namespace :announce do
+    desc &quot;Post news of #{prof_conf.name} to #{rf_conf.project} on rubyforge&quot;
+    task :rubyforge do
+      subject, title, body, urls = announcement
+      rubyforge = RubyForge.new
+      rubyforge.login
+      rubyforge.post_news(rf_conf.project, subject, &quot;#{title}\n\n#{urls}\n\n#{body}&quot;)
+      puts &quot;Posted to rubyforge&quot;
     end
-end
\ No newline at end of file
+
+  end
+end</diff>
      <filename>tasks/rubyforge.rake</filename>
    </modified>
    <modified>
      <diff>@@ -1,39 +1,40 @@
 #-----------------------------------------------------------------------
 # Website maintenance
 #-----------------------------------------------------------------------
+if site_conf = Configuration.for_if_exist(&quot;website&quot;) then
+  namespace :site do
 
-namespace :site do
-    
     desc &quot;Remove all the files from the local deployment of the site&quot;
     task :clobber do
-        rm_rf Stickler::SPEC.local_site_dir
+      rm_rf site_conf.local_dir
     end
 
-    desc &quot;Update the website on #{Stickler::SPEC.remote_site_location}&quot;
+    desc &quot;Update the website on #{site_conf.remote_location}&quot;
     task :deploy =&gt; :build do
-        sh &quot;rsync -zav --delete #{Stickler::SPEC.local_site_dir}/ #{Stickler::SPEC.remote_site_location}&quot;
+      sh &quot;rsync -zav --delete #{site_conf.local_dir} #{site_conf.remote_location}&quot;
     end
 
-    if HAVE_WEBBY then
-        desc &quot;Create the initial webiste template&quot;
-        task :init do
-            Dir.chdir Stickler::ROOT_DIR do
-                ::Webby::Main.run([&quot;website&quot;])
-            end
-            puts &quot;You will need to edit the website/tasks/setup.rb file at this time.&quot;
+    if try_lib(&quot;webby&quot;) then
+      desc &quot;Create the initial webiste template&quot;
+      task :init do
+        Dir.chdir Stickler::Configuration.root_dir do
+          ::Webby::Main.run([&quot;website&quot;])
         end
-        
-        desc &quot;Build the public website&quot;
-        task :build do
-            sh &quot;pushd website &amp;&amp; rake&quot;
-        end
-    end
+        puts &quot;You will need to edit the website/tasks/setup.rb file at this time.&quot;
+      end
 
-    if HAVE_HEEL then
-        desc &quot;View the website locally&quot;
-        task :view =&gt; :build do
-            sh &quot;heel --root #{Stickler::SPEC.local_site_dir}&quot;
-        end
+      desc &quot;Build the public website&quot;
+      task :build do
+        sh &quot;pushd website &amp;&amp; rake&quot;
+      end
     end
 
-end
\ No newline at end of file
+
+    if try_lib(&quot;heel&quot;) then
+      desc &quot;View the website locally&quot;
+      task :view =&gt; :build do
+        sh &quot;heel --root #{site_conf.local_dir}&quot;
+      end
+    end
+  end
+end</diff>
      <filename>tasks/site.rake</filename>
    </modified>
  </modified>
  <removed type="array">
    <removed>
      <filename>CHANGES</filename>
    </removed>
    <removed>
      <filename>lib/stickler/gemspec.rb</filename>
    </removed>
    <removed>
      <filename>lib/stickler/specification.rb</filename>
    </removed>
    <removed>
      <filename>tasks/setup.rb</filename>
    </removed>
  </removed>
  <parents type="array">
    <parent>
      <id>13d1a6c12dbf061683f51237ca8168d1252665a4</id>
    </parent>
  </parents>
  <author>
    <name></name>
    <email>jeremy@hinegardner.org</email>
  </author>
  <url>http://github.com/copiousfreetime/stickler/commit/fe99db58f7bc9a4c2c5121ec2c0f70f551840180</url>
  <id>fe99db58f7bc9a4c2c5121ec2c0f70f551840180</id>
  <committed-date>2008-06-21T23:06:31-07:00</committed-date>
  <authored-date>2008-02-24T21:33:28-08:00</authored-date>
  <message>project structure in place


20080225053328-42483-1d081328a7beb6e658c1838e6eea357e62f4f348.gz</message>
  <tree>3677ef1814152fece3859d2b583ad67d688c660b</tree>
  <committer>
    <name>git-darcs-import &lt;&gt;</name>
    <email nil="true"></email>
  </committer>
</commit>
