Sha256: 4d8c122f73df21c4f25e75493150203bd588dac4ac48fb9f3a85a729355e0ebc

Contents?: true

Size: 843 Bytes

Versions: 11

Compression:

Stored size: 843 Bytes

Contents

# $Id: manifest.rake 11 2007-08-23 15:45:16Z tim_pease $

require 'find'

namespace :manifest do

  desc 'Verify the manfiest'
  task :check do
    fn = 'Manifest.tmp'
    files = []
    exclude = Regexp.new(PROJ.exclude.join('|'))
    Find.find '.' do |path|
      next unless test ?f, path
      next if path =~ exclude
      files << path[2..-1]
    end

    File.open(fn, 'w') {|fp| fp.puts files.sort}
    system "#{DIFF} -du Manifest.txt #{fn}"
    rm fn rescue nil
  end

  desc 'Create a new manifest'
  task :create do
    fn = 'Manifest.txt'
    files = []
    exclude = Regexp.new(PROJ.exclude.join('|'))
    Find.find '.' do |path|
      next unless test ?f, path
      next if path =~ exclude
      files << path[2..-1]
    end

    files << fn unless test ?f, fn
    File.open(fn, 'w') {|fp| fp.puts files.sort}
  end
end

# EOF

Version data entries

11 entries across 11 versions & 2 rubygems

Version Path
logging-0.5.1 tasks/manifest.rake
logging-0.5.2 tasks/manifest.rake
logging-0.5.0 tasks/manifest.rake
logging-0.5.3 tasks/manifest.rake
logging-0.6.0 rakelib/manifest.rake
webby-0.6.0 tasks/manifest.rake
webby-0.5.0 tasks/manifest.rake
webby-0.4.0 tasks/manifest.rake
webby-0.3.0 tasks/manifest.rake
webby-0.2.0 tasks/manifest.rake
webby-0.5.1 tasks/manifest.rake