vendor/gems/BlueCloth-1.0.0/utils.rb
### Write a new manifest file with the given +named+, moving any current one
### aside with an ".old" suffix if +backup+ is true.
Write a new manifest file with the given +named+, moving any current one
aside with an ".old" suffix if +backup+ is true.
Write a new manifest file with the given + named + moving any current one aside with an " . old " suffix if + backup + is true .
def makeManifest( name="MANIFEST", backup=true )
		message "Making manifest file '#{name}'"
		if backup and File::exists?( name )
			File::rename( name, name + ".old" )
		end
		File::open( name, File::WRONLY|File::TRUNC|File::CREAT ) {|ofh|
			Find::find( "." ) do |file|
				Find.prune if AMRegexp =~ file
				Find.prune if %r{/\.} =~ file
				Find.prune if /TEMPLATE/ =~ file
				next if File::directory?( file )
				ofh.puts file
			end
		}
	end
def makeManifest ( name = "MANIFEST" , backup = true ) message "Making manifest file '#{name}'" if backup and File :: exists? ( name ) File :: rename ( name , name + ".old" ) end File :: open ( name , File :: WRONLY | File :: TRUNC | File :: CREAT ) { | ofh | Find :: find ( "." ) do | file | Find . prune if AMRegexp =~ file Find . prune if %r{ / \. } =~ file Find . prune if / TEMPLATE / =~ file next if File :: directory? ( file ) ofh . puts file end } end
Write a new manifest file with the given +named+, moving any current one
aside with an ".old" suffix if +backup+ is true.
Write a new manifest file with the given + named + moving any current one aside with an " . old " suffix if + backup + is true .
# Move an old one aside if a backup is desired
name
<not_specific>
backup
<not_specific>