Changeset 50

Show
Ignore:
Timestamp:
08/13/08 14:57:18 (3 months ago)
Author:
deveiant
Message:

Converting to the new build system

Location:
trunk
Files:
1 added
4 modified

Legend:

Unmodified
Added
Removed
  • trunk

    • Property svn:externals set to
  • trunk/LICENSE

    r45 r50  
    1 Copyright (c) 2004-2008, The FaerieMUD Consortium 
    2  
     1Copyright (c) 2008, Michael Granger 
    32All rights reserved. 
    43 
    5 Redistribution and use in source and binary forms, with or without modification, are 
    6 permitted provided that the following conditions are met: 
     4Redistribution and use in source and binary forms, with or without 
     5modification, are permitted provided that the following conditions are met: 
    76 
    8 * Redistributions of source code must retain the above copyright notice, this 
    9   list of conditions and the following disclaimer. 
     7  * Redistributions of source code must retain the above copyright notice, 
     8    this list of conditions and the following disclaimer. 
    109 
    11 * Redistributions in binary form must reproduce the above copyright notice, this 
    12   list of conditions and the following disclaimer in the documentation and/or 
    13   other materials provided with the distribution. 
     10  * Redistributions in binary form must reproduce the above copyright notice, 
     11    this list of conditions and the following disclaimer in the documentation 
     12    and/or other materials provided with the distribution. 
    1413 
    15 * Neither the name of the FaerieMUD Consortium nor the names of its contributors 
    16   may be used to endorse or promote products derived from this software without 
    17   specific prior written permission. 
     14  * Neither the name of the author/s, nor the names of the project's 
     15    contributors may be used to endorse or promote products derived from this 
     16    software without specific prior written permission. 
    1817 
    19 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
    20 "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
    21 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 
    22 A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR 
    23 CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 
    24 EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 
    25 PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 
    26 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF 
    27 LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING 
    28 NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 
    29 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 
    30  
     18THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 
     19AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 
     20IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 
     21DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE 
     22FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 
     23DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 
     24SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
     25CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 
     26OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 
     27OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 
  • trunk/README

    r45 r50  
    22= PluginFactory 
    33 
    4 PluginFactory is a mixin module turns an including class into a factory for its 
    5 derivatives, capable of searching for and loading them by name. This is useful 
    6 when you have an abstract base class which defines an interface and basic 
     4PluginFactory is a mixin module that turns an including class into a factory for 
     5its derivatives, capable of searching for and loading them by name. This is 
     6useful when you have an abstract base class which defines an interface and basic 
    77functionality for a part of a larger system, and a collection of subclasses 
    88which implement the interface for different underlying functionality. 
  • trunk/Rakefile

    r48 r50  
    55# Based on various other Rakefiles, especially one by Ben Bleything 
    66# 
    7 # Copyright (c) 2007-2008 The FaerieMUD Consortium 
     7# Copyright (c) 2008 The FaerieMUD Consortium 
    88# 
    99# Authors: 
     
    1414    require 'pathname' 
    1515    basedir = Pathname.new( __FILE__ ).dirname 
     16 
    1617    libdir = basedir + "lib" 
     18    extdir = basedir + "ext" 
    1719 
    1820    $LOAD_PATH.unshift( libdir.to_s ) unless $LOAD_PATH.include?( libdir.to_s ) 
     21    $LOAD_PATH.unshift( extdir.to_s ) unless $LOAD_PATH.include?( extdir.to_s ) 
    1922} 
    2023 
    21  
    22 require 'pluginfactory' 
    2324 
    2425require 'rbconfig' 
     
    2829require 'rake/testtask' 
    2930require 'rake/packagetask' 
     31require 'rake/clean' 
    3032 
    3133$dryrun = false 
    3234 
    3335### Config constants 
    34 PKG_NAME      = 'PluginFactory' 
    35 PKG_SUMMARY   = 'A mixin module for creating plugin classes' 
    36 PKG_VERSION   = PluginFactory::VERSION 
     36BASEDIR       = Pathname.new( __FILE__ ).dirname.relative_path_from( Pathname.getwd ) 
     37LIBDIR        = BASEDIR + 'lib' 
     38EXTDIR        = BASEDIR + 'ext' 
     39DOCSDIR       = BASEDIR + 'docs' 
     40PKGDIR        = BASEDIR + 'pkg' 
     41 
     42PKG_NAME      = 'pluginfactory' 
     43PKG_SUMMARY   = 'A mixin for making plugin classes' 
     44VERSION_FILE  = LIBDIR + 'pluginfactory.rb' 
     45PKG_VERSION   = VERSION_FILE.read[ /VERSION = '(\d+\.\d+\.\d+)'/, 1 ] 
    3746PKG_FILE_NAME = "#{PKG_NAME.downcase}-#{PKG_VERSION}" 
    3847GEM_FILE_NAME = "#{PKG_FILE_NAME}.gem" 
    3948 
    40 RELEASE_NAME  = "RELEASE_#{PKG_VERSION.gsub(/\./, '_')}" 
    41  
    42 BASEDIR       = Pathname.new( __FILE__ ).dirname.relative_path_from( Pathname.getwd ) 
    43 LIBDIR        = BASEDIR + 'lib' 
    44 DOCSDIR       = BASEDIR + 'docs' 
    45 PKGDIR        = BASEDIR + 'pkg' 
    46  
    47 ARTIFACTS_DIR = Pathname.new( ENV['CC_BUILD_ARTIFACTS'] || '' ) 
    48  
    49 TEXT_FILES    = %w( Rakefile ChangeLog README LICENSE ). 
    50     collect {|filename| BASEDIR + filename } 
    51 LIB_FILES     = Pathname.glob( LIBDIR + '**/*.rb'). 
    52     delete_if {|item| item =~ /\.svn/ } 
     49ARTIFACTS_DIR = Pathname.new( ENV['CC_BUILD_ARTIFACTS'] || 'artifacts' ) 
     50 
     51TEXT_FILES    = %w( Rakefile ChangeLog README LICENSE ).collect {|filename| BASEDIR + filename } 
     52LIB_FILES     = Pathname.glob( LIBDIR + '**/*.rb' ).delete_if {|item| item =~ /\.svn/ } 
     53EXT_FILES     = Pathname.glob( EXTDIR + '**/*.{c,h,rb}' ).delete_if {|item| item =~ /\.svn/ } 
    5354 
    5455SPECDIR       = BASEDIR + 'spec' 
    55 SPEC_FILES    = Pathname.glob( SPECDIR + '**/*_spec.rb' ). 
    56     delete_if {|item| item =~ /\.svn/ } 
    57 SPEC_EXCLUDES = 'spec,/Library/Ruby,/var/lib,/usr/local/lib' 
    58  
    59  
    60 RELEASE_FILES = TEXT_FILES + SPEC_FILES + LIB_FILES 
    61  
    62 # Load task plugins 
    63 RAKE_TASKDIR = BASEDIR + 'rake' 
    64 Pathname.glob( RAKE_TASKDIR + '*.rb' ).each do |tasklib| 
    65     require tasklib 
    66 end 
     56SPEC_FILES    = Pathname.glob( SPECDIR + '**/*_spec.rb' ).delete_if {|item| item =~ /\.svn/ } 
     57 
     58TESTDIR       = BASEDIR + 'tests' 
     59TEST_FILES    = Pathname.glob( TESTDIR + '**/*.tests.rb' ).delete_if {|item| item =~ /\.svn/ } 
     60 
     61RAKE_TASKDIR  = BASEDIR + 'rake' 
     62RAKE_TASKLIBS = Pathname.glob( RAKE_TASKDIR + '*.rb' ) 
     63 
     64LOCAL_RAKEFILE = BASEDIR + 'Rakefile.local' 
     65 
     66EXTRA_PKGFILES = [] 
     67 
     68RELEASE_FILES = TEXT_FILES +  
     69    SPEC_FILES +  
     70    TEST_FILES +  
     71    LIB_FILES +  
     72    EXT_FILES +  
     73    RAKE_TASKLIBS + 
     74    EXTRA_PKGFILES 
     75 
     76RELEASE_FILES << LOCAL_RAKEFILE if LOCAL_RAKEFILE.exist? 
     77 
     78COVERAGE_MINIMUM = ENV['COVERAGE_MINIMUM'] ? Float( ENV['COVERAGE_MINIMUM'] ) : 85.0 
     79RCOV_EXCLUDES = 'spec,tests,/Library/Ruby,/var/lib,/usr/local/lib' 
     80RCOV_OPTS = [ 
     81    '--exclude', RCOV_EXCLUDES, 
     82    '--xrefs', 
     83    '--save', 
     84    '--callsites', 
     85    #'--aggregate', 'coverage.data' # <- doesn't work as of 0.8.1.2.0 
     86  ] 
     87 
     88 
     89# Subversion constants -- directory names for releases and tags 
     90SVN_TRUNK_DIR    = 'trunk' 
     91SVN_RELEASES_DIR = 'releases' 
     92SVN_BRANCHES_DIR = 'branches' 
     93SVN_TAGS_DIR     = 'tags' 
     94 
     95SVN_DOTDIR       = BASEDIR + '.svn' 
     96SVN_ENTRIES      = SVN_DOTDIR + 'entries' 
     97 
     98 
     99### Load some task libraries that need to be loaded early 
     100require RAKE_TASKDIR + 'helpers.rb' 
     101require RAKE_TASKDIR + 'svn.rb' 
     102require RAKE_TASKDIR + 'verifytask.rb' 
    67103 
    68104# Define some constants that depend on the 'svn' tasklib 
     
    77113    '-i', '.', 
    78114    '-m', 'README', 
    79     '-W', 'http://deveiate.org/projects/PluginFactory/browser/trunk/' 
     115    '-W', 'http://deveiate.org/projects/PluginFactory//browser/trunk/' 
    80116  ] 
    81117 
     
    90126PROJECT_SCPURL = "#{PROJECT_HOST}:#{PROJECT_DOCDIR}" 
    91127 
     128# Rubyforge stuff 
     129RUBYFORGE_GROUP = 'deveiate' 
     130RUBYFORGE_PROJECT = 'pluginfactory' 
     131 
     132# Gem dependencies: gemname => version 
     133DEPENDENCIES = { 
     134} 
     135 
     136# Non-gem requirements: packagename => version 
     137REQUIREMENTS = { 
     138} 
     139 
    92140# RubyGem specification 
    93141GEMSPEC   = Gem::Specification.new do |gem| 
     
    97145    gem.summary           = PKG_SUMMARY 
    98146    gem.description       = <<-EOD 
    99     PluginFactory is a mixin module that adds pluggable behavior to including 
    100     classes, allowing you to require and instantiate its subclasses by name via a  
    101     factory method. 
     147    PluginFactory is a mixin module that turns an including class into a factory for 
     148    its derivatives, capable of searching for and loading them by name. This is 
     149    useful when you have an abstract base class which defines an interface and basic 
     150    functionality for a part of a larger system, and a collection of subclasses 
     151    which implement the interface for different underlying functionality. 
    102152    EOD 
    103153 
    104     gem.authors           = "Michael Granger, Martin Chase" 
     154    gem.authors           = 'Michael Granger' 
    105155    gem.email             = 'ged@FaerieMUD.org' 
    106     gem.homepage          = "http://deveiate.org/projects/PluginFactory" 
    107     gem.rubyforge_project = 'deveiate' 
     156    gem.homepage          = 'http://deveiate.org/projects/PluginFactory/' 
     157    gem.rubyforge_project = RUBYFORGE_PROJECT 
    108158 
    109159    gem.has_rdoc          = true 
     
    114164    gem.test_files        = SPEC_FILES. 
    115165        collect {|f| f.relative_path_from(BASEDIR).to_s } 
    116 end 
    117  
    118  
    119  
    120 if Rake.application.options.trace 
    121     $trace = true 
    122     log "$trace is enabled" 
    123 end 
    124  
    125 if Rake.application.options.dryrun 
    126     $dryrun = true 
    127     log "$dryrun is enabled" 
    128 end 
     166         
     167    DEPENDENCIES.each do |name, version| 
     168        version = '>= 0' if version.length.zero? 
     169        gem.add_dependency( name, version ) 
     170    end 
     171     
     172    REQUIREMENTS.each do |name, version| 
     173        gem.requirements << [ name, version ].compact.join(' ') 
     174    end 
     175end 
     176 
     177$trace = Rake.application.options.trace ? true : false 
     178$dryrun = Rake.application.options.dryrun ? true : false 
     179 
     180 
     181# Load any remaining task libraries 
     182RAKE_TASKLIBS.each do |tasklib| 
     183    next if tasklib =~ %r{/(helpers|svn|verifytask)\.rb$} 
     184    begin 
     185        require tasklib 
     186    rescue ScriptError => err 
     187        fail "Task library '%s' failed to load: %s: %s" % 
     188            [ tasklib, err.class.name, err.message ] 
     189        trace "Backtrace: \n  " + err.backtrace.join( "\n  " ) 
     190    rescue => err 
     191        log "Task library '%s' failed to load: %s: %s. Some tasks may not be available." % 
     192            [ tasklib, err.class.name, err.message ] 
     193        trace "Backtrace: \n  " + err.backtrace.join( "\n  " ) 
     194    end 
     195end 
     196 
     197# Load any project-specific rules defined in 'Rakefile.local' if it exists 
     198import LOCAL_RAKEFILE if LOCAL_RAKEFILE.exist? 
     199 
     200 
     201##################################################################### 
     202### T A S K S    
     203##################################################################### 
    129204 
    130205### Default task 
    131 task :default  => [:clean, :spec, :rdoc, :package] 
     206task :default  => [:clean, :local, :spec, :rdoc, :package] 
     207 
     208### Task the local Rakefile can append to -- no-op by default 
     209task :local 
    132210 
    133211 
    134212### Task: clean 
    135 desc "Clean pkg, coverage, and rdoc; remove .bak files" 
    136 task :clean => [ :clobber_rdoc, :clobber_package ] do 
    137     files = FileList['**/*.bak'] 
    138     files.clear_exclude 
    139     File.rm( files ) unless files.empty? 
    140     FileUtils.rm_rf( 'artifacts' ) 
    141 end 
    142  
    143  
    144 begin 
    145     gem 'darkfish-rdoc' 
    146  
    147     Rake::RDocTask.new do |rdoc| 
    148         rdoc.rdoc_dir = 'docs' 
    149         rdoc.title    = "#{PKG_NAME} - #{PKG_SUMMARY}" 
    150         rdoc.options += RDOC_OPTIONS + [ '-f', 'darkfish' ] 
    151  
    152         rdoc.rdoc_files.include 'README' 
    153         rdoc.rdoc_files.include LIB_FILES.collect {|f| f.to_s } 
    154     end 
    155 rescue LoadError, Gem::Exception => err 
    156     if !Object.const_defined?( :Gem ) 
    157         require 'rubygem' 
    158         retry 
    159     end 
    160      
    161     task :no_darkfish do 
    162         fail "Could not generate RDoc: %s" % [ err.message ] 
    163     end 
    164     task :docs => :no_darkfish 
    165 end 
    166  
    167  
    168 ### Task: package 
    169 Rake::PackageTask.new( PKG_NAME, PKG_VERSION ) do |task| 
    170     task.need_tar_gz   = true 
    171     task.need_tar_bz2  = true 
    172     task.need_zip      = true 
    173     task.package_dir   = PKGDIR.to_s 
    174     task.package_files = RELEASE_FILES. 
    175         collect {|f| f.relative_path_from(BASEDIR).to_s } 
    176 end 
    177 task :package => [:gem] 
    178  
    179  
    180 ### Task: gem 
    181 gempath = PKGDIR + GEM_FILE_NAME 
    182  
    183 desc "Build a RubyGem package (#{GEM_FILE_NAME})" 
    184 task :gem => gempath.to_s 
    185 file gempath.to_s => [PKGDIR.to_s] + GEMSPEC.files do 
    186     when_writing( "Creating GEM" ) do 
    187         Gem::Builder.new( GEMSPEC ).build 
    188         verbose( true ) do 
    189             mv GEM_FILE_NAME, gempath 
    190         end 
    191     end 
    192 end 
    193  
    194 ### Task: install 
    195 desc "Install PluginFactory as a conventional library" 
    196 task :install do 
    197     log "Installing PluginFactory as a conventional library" 
    198     sitelib = Pathname.new( CONFIG['sitelibdir'] ) 
    199     Dir.chdir( LIBDIR ) do 
    200         LIB_FILES.each do |libfile| 
    201             relpath = libfile.relative_path_from( LIBDIR ) 
    202             target = sitelib + relpath 
    203             FileUtils.mkpath target.dirname, 
    204                 :mode => 0755, :verbose => true, :noop => $dryrun unless target.dirname.directory? 
    205             FileUtils.install relpath, target, 
    206                 :mode => 0644, :verbose => true, :noop => $dryrun 
    207         end 
    208     end 
    209 end 
    210  
    211  
    212  
    213 ### Task: install_gem 
    214 desc "Install PluginFactory from a locally-built gem" 
    215 task :install_gem => [:package] do 
    216     $stderr.puts  
    217     installer = Gem::Installer.new( %{pkg/#{PKG_FILE_NAME}.gem} ) 
    218     installer.install 
    219 end 
    220  
    221 ### Task: uninstall_gem 
    222 desc "Install the PluginFactory gem" 
    223 task :uninstall_gem => [:clean] do 
    224     uninstaller = Gem::Uninstaller.new( PKG_FILE_NAME ) 
    225     uninstaller.uninstall 
    226 end 
    227  
    228  
    229  
    230 ### Cruisecontrol task 
     213CLEAN.include 'coverage' 
     214CLOBBER.include 'artifacts', 'coverage.info', PKGDIR 
     215 
     216# Target to hinge on ChangeLog updates 
     217file SVN_ENTRIES 
     218 
     219### Task: changelog 
     220file 'ChangeLog' => SVN_ENTRIES.to_s do |task| 
     221    log "Updating #{task.name}" 
     222 
     223    changelog = make_svn_changelog() 
     224    File.open( task.name, 'w' ) do |fh| 
     225        fh.print( changelog ) 
     226    end 
     227end 
     228 
     229 
     230### Task: cruise (Cruisecontrol task) 
    231231desc "Cruisecontrol build" 
    232232task :cruise => [:clean, :spec, :package] do |task| 
     
    243243 
    244244 
    245 ### RSpec tasks 
    246 begin 
    247     gem 'rspec', '>= 1.0.5' 
    248     require 'spec/rake/spectask' 
    249  
    250     ### Task: spec 
    251     Spec::Rake::SpecTask.new( :spec ) do |task| 
    252         task.spec_files = SPEC_FILES 
    253         task.libs += [LIBDIR] 
    254         task.spec_opts = ['-c', '-f','s', '-b', '-D', 'u'] 
    255     end 
    256     task :test => [:spec] 
    257  
    258  
    259     namespace :spec do 
    260  
    261         desc "Run rspec every time there's a change to one of the files" 
    262         task :autotest do 
    263             gem 'ZenTest', ">= 3.6.0" 
    264             require 'autotest/rspec' 
    265             autotester = Autotest::Rspec.new 
    266             autotester.exceptions = %r{\.svn|\.skel} 
    267             autotester.test_mappings = { 
    268                 %r{^spec/.*\.rb$} => proc {|filename, _| 
    269                     filename 
    270                 }, 
    271                 %r{^lib/[^/]*\.rb$} => proc {|_, m| 
    272                     ["spec/#{m[1]}_spec.rb"] 
    273                 }, 
    274             } 
    275              
    276             autotester.run 
    277         end 
    278  
    279      
    280         desc "Generate HTML output for a spec run" 
    281         Spec::Rake::SpecTask.new( :html ) do |task| 
    282             task.spec_files = SPEC_FILES 
    283             task.spec_opts = ['-f','h', '-D'] 
    284         end 
    285  
    286         desc "Generate plain-text output for a CruiseControl.rb build" 
    287         Spec::Rake::SpecTask.new( :text ) do |task| 
    288             task.spec_files = SPEC_FILES 
    289             task.spec_opts = ['-f','p'] 
    290         end 
    291     end 
    292 rescue LoadError => err 
    293     task :no_rspec do 
    294         $stderr.puts "Testing tasks not defined: RSpec rake tasklib not available: %s" % 
    295             [ err.message ] 
    296     end 
    297      
    298     task :spec => :no_rspec 
    299     namespace :spec do 
    300         task :autotest => :no_rspec 
    301         task :html => :no_rspec 
    302         task :text => :no_rspec 
    303     end 
    304 end 
    305  
    306  
    307 RCOV_OPTS = [ 
    308     '--exclude', SPEC_EXCLUDES, 
    309     '--xrefs', 
    310     '--save', 
    311     '--callsites' 
    312   ] 
    313  
    314 ### RCov (via RSpec) tasks 
    315 begin 
    316     gem 'rcov', '>= 0.8.0.1' 
    317     gem 'rspec', '>= 1.0.5' 
    318  
    319     ### Task: coverage (via RCov) 
    320     ### Task: spec 
    321     desc "Build test coverage reports" 
    322     Spec::Rake::SpecTask.new( :coverage ) do |task| 
    323         task.spec_files = SPEC_FILES 
    324         task.libs += [LIBDIR] 
    325         task.spec_opts = ['-f', 'p', '-b'] 
    326         task.rcov_opts = RCOV_OPTS 
    327         task.rcov = true 
    328     end 
    329  
    330     task :rcov => [:coverage] do; end 
    331      
    332  
    333     ### Other coverage tasks 
    334     namespace :coverage do 
    335         desc "Generate a detailed text coverage report" 
    336         Spec::Rake::SpecTask.new( :text ) do |task| 
    337             task.spec_files = SPEC_FILES 
    338             task.rcov_opts = RCOV_OPTS + ['--text-coverage'] 
    339             task.rcov = true 
    340         end 
    341  
    342         desc "Show differences in coverage from last run" 
    343         Spec::Rake::SpecTask.new( :diff ) do |task| 
    344             task.spec_files = SPEC_FILES 
    345             task.rcov_opts = ['--text-coverage-diff'] 
    346             task.rcov = true 
    347         end 
    348  
    349         ### Task: verify coverage 
    350         desc "Build coverage statistics" 
    351         VerifyTask.new( :verify => :rcov ) do |task| 
    352             task.threshold = 85.0 
    353         end 
    354     end 
    355  
    356  
    357 rescue LoadError => err 
    358     task :no_rcov do 
    359         $stderr.puts "Coverage tasks not defined: RSpec+RCov tasklib not available: %s" % 
    360             [ err.message ] 
    361     end 
    362  
    363     task :coverage => :no_rcov 
    364     task :clobber_coverage 
    365     task :rcov => :no_rcov 
    366     namespace :coverage do 
    367         task :text => :no_rcov 
    368         task :diff => :no_rcov 
    369     end 
    370     task :verify => :no_rcov 
    371 end 
    372  
    373  
     245desc "Update the build system to the latest version" 
     246task :update_build do 
     247    log "Updating the build system" 
     248    sh 'svn', 'up', RAKE_TASKDIR 
     249    log "Updating the Rakefile" 
     250    sh 'rake', '-f', RAKE_TASKDIR + 'Metarakefile' 
     251end 
     252