reap 6.0.0 → 6.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/ProjectInfo +102 -0
- data/data/reap/install.rb +62 -0
- data/forge/ProjectInfo +38 -0
- data/forge/ProjectInfo.rb +76 -0
- data/forge/TODO +10 -0
- data/forge/installer.rb +250 -0
- data/forge/reference/Rakefile +124 -0
- data/forge/reference/Rakefile.htm +69 -0
- data/forge/reference/aRakefile +60 -0
- data/forge/reference/compositepublisher.rb +24 -0
- data/forge/reference/ftptools.rb +139 -0
- data/forge/reference/installers/package.rb +629 -0
- data/forge/reference/installers/setup.rb +1558 -0
- data/forge/reference/license-each.rb +85 -0
- data/forge/reference/publisher.rb +75 -0
- data/forge/reference/rubyforge.rb +247 -0
- data/forge/reference/rubyforgepublisher.rb +18 -0
- data/forge/reference/sshpublisher.rb +47 -0
- data/forge/reference/suby-cvs.rb +46 -0
- data/forge/scaffold.rb +126 -0
- data/forge/unit_runner/README +6 -0
- data/forge/unit_runner/commentrunner.rb +62 -0
- data/forge/unit_runner/cunit.rb +17 -0
- data/forge/unit_runner/forkedrunner.rb +91 -0
- data/forge/unit_runner/sample.rb +16 -0
- data/lib/reap/class/extest.rb +2 -7
- data/lib/reap/class/manifest.rb +7 -11
- data/lib/reap/class/package.rb +120 -25
- data/lib/reap/class/rdoc.rb +1 -9
- data/lib/reap/class/test.rb +2 -7
- data/lib/reap/tasks.rb +51 -58
- data/note/LATEST +44 -0
- data/note/doap.xml +28 -0
- data/note/history/Rakefile-0.1 +308 -0
- data/web/ProjectInfo.html +80 -0
- data/web/images/grape.jpg +0 -0
- data/web/index.html +312 -0
- metadata +66 -27
- data/lib/reap/class/installer.rb +0 -178
data/note/LATEST
ADDED
@@ -0,0 +1,44 @@
|
|
1
|
+
|
2
|
+
One hop, a skip and a jump. In just suca a fashion we're on to
|
3
|
+
the next major veriosn of Reap. Reap 6 has now reached a whole
|
4
|
+
new level of elegance and capability. The core of the system has
|
5
|
+
been completely rewritten, thanks to lessons learned from the
|
6
|
+
previous incarnations and honoring the defacto standard of Rake's
|
7
|
+
task definitions, a Reap task is now easily defined like so:
|
8
|
+
|
9
|
+
module Tasks
|
10
|
+
|
11
|
+
def footask( name, &data )
|
12
|
+
|
13
|
+
desc "Describing a foo task"
|
14
|
+
|
15
|
+
task name do
|
16
|
+
data = data.to_openobject
|
17
|
+
puts "Doing what a foo task #{data.does}!"
|
18
|
+
end
|
19
|
+
|
20
|
+
end
|
21
|
+
|
22
|
+
end
|
23
|
+
|
24
|
+
See the resemblance? Does Reap require Rake? No! Reap has it's
|
25
|
+
own task system that work's like Rake's --provided by Facets'
|
26
|
+
taskable.rb library. And you can use Reap much like you'd use
|
27
|
+
Rake. Indeed, one can resuse Reap's built-in tasks without
|
28
|
+
even setting up a ProjectInfo file. In a Reapfile:
|
29
|
+
|
30
|
+
task_footask 'footask' do |data|
|
31
|
+
data.does = 'does'
|
32
|
+
end
|
33
|
+
|
34
|
+
Yep. You can do that. Of course why you would want to forgo
|
35
|
+
the beauty of the ProjectInfo file and this gorgeous solution?
|
36
|
+
|
37
|
+
footask: !!footask
|
38
|
+
does: 'does'
|
39
|
+
|
40
|
+
That's something for your own conscious to wrestle ;)
|
41
|
+
|
42
|
+
Enjoy,
|
43
|
+
T.
|
44
|
+
|
data/note/doap.xml
ADDED
@@ -0,0 +1,28 @@
|
|
1
|
+
<Project xmlns="http://usefulinc.com/ns/doap#"
|
2
|
+
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
3
|
+
xmlns:foaf="http://xmlns.com/foaf/0.1/">
|
4
|
+
<name>Reap</name>
|
5
|
+
<shortname>reap</shortname>
|
6
|
+
<homepage rdf:resource="http://reap.rubyforge.org" />
|
7
|
+
<wiki rdf:resource="" />
|
8
|
+
<created>2004-04-01</created>
|
9
|
+
<shortdesc xml:lang="en">
|
10
|
+
The Flexible Ruby Project Management Assistant
|
11
|
+
</shortdesc>
|
12
|
+
<description xml:lang="en">
|
13
|
+
Reap comprises a set of tasks commonly needed by
|
14
|
+
Ruby package developers/deployers, such as
|
15
|
+
testing, packaging, releasing, etc. You can also
|
16
|
+
use Reap to create your own custom tasks. Reap
|
17
|
+
utilizes a YAML configuration file to harvest
|
18
|
+
common project information, significantly
|
19
|
+
simplifying these chores.
|
20
|
+
</description>
|
21
|
+
<maintainer>
|
22
|
+
<foaf:Person>
|
23
|
+
<foaf:name>Thomas Sawyer</foaf:name>
|
24
|
+
<foaf:email>transfire@gmail.com</foaf:name>
|
25
|
+
<foaf:homepage rdf:resource="http://reap.rubyforge.org" />
|
26
|
+
</foaf:Person>
|
27
|
+
</maintainer>
|
28
|
+
</Project>
|
@@ -0,0 +1,308 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
PKG_TITLE = 'WhiteCloth'
|
4
|
+
PKG_NAME = 'whitecloth'
|
5
|
+
PKG_VERSION = '1'
|
6
|
+
PKG_AUTHOR = 'Thomas Sawyer'
|
7
|
+
PKG_EMAIL = 'transami@runbox.com'
|
8
|
+
PKG_SUMMARY = 'WhiteCloth is an implementation of ArtML'
|
9
|
+
PKG_DESCRIPTION = 'WhiteCloth is a Ruby implementation of ArtML'
|
10
|
+
|
11
|
+
# site info
|
12
|
+
# remark out if you don't need
|
13
|
+
PKG_HOMEPAGE = 'http://whitecloth.rubyforge.org'
|
14
|
+
PKG_RUBYFORGE_PROJECT = 'whitecloth'
|
15
|
+
PKG_RUBYFORGE_PASS = nil
|
16
|
+
|
17
|
+
# all package files
|
18
|
+
PKG_FILES = [ 'lib/**/*', 'test/**/*', 'samples/**/*', 'doc/**/*', '[A-Z]*', 'Rakefile' ]
|
19
|
+
|
20
|
+
# rdoc
|
21
|
+
RDOC_TITLE = PKG_TITLE
|
22
|
+
RDOC_DIR = 'doc'
|
23
|
+
RDOC_TEMPLATE = 'kilmer'
|
24
|
+
RDOC_OPTIONS = ''
|
25
|
+
RDOC_INCLUDE = [ 'VERSION', 'README', 'CHANGELOG', 'TODO', 'COPYING', 'lib/**/*.rb', 'bin/**/*.rb' ]
|
26
|
+
RDOC_EXCLUDE = []
|
27
|
+
|
28
|
+
# include in distribution
|
29
|
+
PKG_DIST_DIRS = [ 'bin', 'lib', 'test', 'samples' ]
|
30
|
+
PKG_DIST_FILES = [ 'README', 'TODO', 'CHANGELOG', 'VERSION', 'LICENSE', 'Rakefile' ]
|
31
|
+
|
32
|
+
# tests
|
33
|
+
PKG_TEST_DIR = 'test'
|
34
|
+
PKG_TEST_FILES = [ 'test/*_test.rb', 'test/**/*_test.rb' ]
|
35
|
+
|
36
|
+
=begin
|
37
|
+
# library files for manual install
|
38
|
+
PKG_LIB_DIR = 'lib'
|
39
|
+
PKG_LIB_MKDIRS = '**/*/'
|
40
|
+
PKG_LIB_FILES = [ '**/*.rb', '**/*.yaml' ]
|
41
|
+
PKG_LIB_DEPRECATE = []
|
42
|
+
|
43
|
+
# binary files for manual install
|
44
|
+
PKG_BIN_DIR = 'bin'
|
45
|
+
PKG_BIN_FILES = '**/*'
|
46
|
+
PKG_BIN_DEPRECATE = []
|
47
|
+
=end
|
48
|
+
|
49
|
+
#***************************************************************************
|
50
|
+
# The PackMule Rakefile v0.1
|
51
|
+
# PackMule can run tests, build packages and gems, manually install,
|
52
|
+
# generate rdocs, and publish them. CVS support might be added later.
|
53
|
+
#
|
54
|
+
# In general, layout your project directory as follows:
|
55
|
+
# - lib/
|
56
|
+
# - lib/#{lib_name}/ if you need a lib dir
|
57
|
+
# - bin/
|
58
|
+
# - test/
|
59
|
+
# - demo/ -or- examples/ -or- samples/
|
60
|
+
# - doc/ -and;or- rdoc/
|
61
|
+
# The test dir can have subdirs, but tests should be named
|
62
|
+
# like '#{name}_test.rb' or 'test_#{name}.rb'.
|
63
|
+
#
|
64
|
+
# Then use the Rake.yaml config file designed for this form.
|
65
|
+
# To get a blank config for this form type:
|
66
|
+
# > rake form
|
67
|
+
# This will send the form to stdout. There may be a line like
|
68
|
+
# "(in ...)" at the beginning, just remove it or remark it.
|
69
|
+
#***************************************************************************
|
70
|
+
|
71
|
+
require 'rake'
|
72
|
+
require 'rubygems'
|
73
|
+
require 'rake/testtask'
|
74
|
+
require 'rake/rdoctask'
|
75
|
+
require 'rake/packagetask'
|
76
|
+
require 'rake/gempackagetask'
|
77
|
+
require 'rake/contrib/rubyforgepublisher'
|
78
|
+
|
79
|
+
#################################################
|
80
|
+
# load config from Rake.yaml and make constants #
|
81
|
+
#################################################
|
82
|
+
#YAML::load( File.open('Rake.yaml') ).each{|c,v| self.class.const_set(c,v)}
|
83
|
+
|
84
|
+
|
85
|
+
##
|
86
|
+
# = Default Task
|
87
|
+
##
|
88
|
+
|
89
|
+
desc "Default Task (test)"
|
90
|
+
task :default => [ :test ]
|
91
|
+
|
92
|
+
|
93
|
+
##
|
94
|
+
# = Run Unit Tests
|
95
|
+
##
|
96
|
+
|
97
|
+
Rake::TestTask.new("test") { |t|
|
98
|
+
#t.desc "Run all tests"
|
99
|
+
t.libs << PKG_TEST_DIR
|
100
|
+
PKG_TEST_FILES.each { |pat| t.pattern = pat }
|
101
|
+
t.verbose = true
|
102
|
+
}
|
103
|
+
|
104
|
+
|
105
|
+
##
|
106
|
+
# = Genereate RDoc Documentation
|
107
|
+
##
|
108
|
+
|
109
|
+
Rake::RDocTask.new { |rdoc|
|
110
|
+
rdoc.rdoc_dir = RDOC_DIR
|
111
|
+
rdoc.template = RDOC_TEMPLATE
|
112
|
+
rdoc.title = RDOC_TITLE
|
113
|
+
rdoc.options << '--line-numbers --inline-source ' + RDOC_OPTIONS
|
114
|
+
rdoc.rdoc_files.include(*RDOC_INCLUDE)
|
115
|
+
rdoc.rdoc_files.exclude(*RDOC_EXCLUDE)
|
116
|
+
rdoc.rdoc_files.delete_if { |f| ! File.exist?(f) }
|
117
|
+
}
|
118
|
+
|
119
|
+
|
120
|
+
##
|
121
|
+
# = Publish Documentation
|
122
|
+
##
|
123
|
+
|
124
|
+
# Publish documentation
|
125
|
+
#desc "Publish the API documentation"
|
126
|
+
#task :pdoc => [:rdoc] do
|
127
|
+
# Rake::SshDirPublisher.new("david@hunter.5th.dk", "sites/rubyonrails.org/ar", "doc").upload
|
128
|
+
#end
|
129
|
+
|
130
|
+
if PKG_RUBYFORGE_PROJECT
|
131
|
+
desc "Publish to RubyForge"
|
132
|
+
task :rubyforge do
|
133
|
+
Rake::RubyForgePublisher.new(PKG_RUBYFORGE_PROJECT, PKG_RUBYFORGE_PASS).upload
|
134
|
+
end
|
135
|
+
end
|
136
|
+
|
137
|
+
|
138
|
+
##
|
139
|
+
# = Create Compressed Packages
|
140
|
+
##
|
141
|
+
|
142
|
+
dist_dirs = PKG_DIST_DIRS
|
143
|
+
|
144
|
+
spec = Gem::Specification.new do |s|
|
145
|
+
s.name = PKG_NAME
|
146
|
+
s.version = PKG_VERSION
|
147
|
+
s.summary = PKG_SUMMARY
|
148
|
+
s.description = PKG_DESCRIPTION
|
149
|
+
|
150
|
+
s.files = PKG_DIST_FILES
|
151
|
+
dist_dirs.each do |dir|
|
152
|
+
s.files.concat Dir.glob( "#{dir}/**/*" ).delete_if { |item| item.include?( "CVS" ) }
|
153
|
+
end
|
154
|
+
#s.files.delete "test/fixtures/fixture_database.sqlite"
|
155
|
+
s.require_path = 'lib'
|
156
|
+
s.autorequire = '#{PKG_NAME}'
|
157
|
+
s.has_rdoc = true
|
158
|
+
s.author = PKG_AUTHOR
|
159
|
+
s.email = PKG_EMAIL
|
160
|
+
s.homepage = PKG_HOMEPAGE if PKG_HOMEPAGE
|
161
|
+
s.rubyforge_project = PKG_RUBYFORGE_PROJECT if PKG_RUBYFORGE_PROJECT
|
162
|
+
end
|
163
|
+
|
164
|
+
Rake::GemPackageTask.new(spec) do |p|
|
165
|
+
p.gem_spec = spec
|
166
|
+
p.need_tar = true
|
167
|
+
p.need_zip = true
|
168
|
+
end
|
169
|
+
|
170
|
+
|
171
|
+
##
|
172
|
+
# = Line Count
|
173
|
+
##
|
174
|
+
|
175
|
+
desc "Line Count"
|
176
|
+
task :lines do
|
177
|
+
lines = 0
|
178
|
+
codelines = 0
|
179
|
+
Dir.foreach("lib/#{PKG_NAME}") { |file_name|
|
180
|
+
next unless file_name =~ /.*rb/
|
181
|
+
|
182
|
+
f = File.open("lib/#{PKG_NAME}/" + file_name)
|
183
|
+
|
184
|
+
while line = f.gets
|
185
|
+
lines += 1
|
186
|
+
next if line =~ /^\s*$/
|
187
|
+
next if line =~ /^\s*#/
|
188
|
+
codelines += 1
|
189
|
+
end
|
190
|
+
}
|
191
|
+
puts "Lines #{lines}, LOC #{codelines}"
|
192
|
+
end
|
193
|
+
|
194
|
+
|
195
|
+
=begin
|
196
|
+
##
|
197
|
+
# = Manual Install
|
198
|
+
##
|
199
|
+
|
200
|
+
desc "Manual Installation"
|
201
|
+
task :install do
|
202
|
+
|
203
|
+
# install
|
204
|
+
# this was adapted from active record's install.rb
|
205
|
+
# by way of rdoc's install.rb
|
206
|
+
# by way of Log4r's install.rb
|
207
|
+
# with some modifications from ruby-gems' install.rb ;)
|
208
|
+
|
209
|
+
require 'rbconfig'
|
210
|
+
require 'find'
|
211
|
+
require 'ftools'
|
212
|
+
require 'fileutils'
|
213
|
+
|
214
|
+
include Config
|
215
|
+
|
216
|
+
#$sitedir = CONFIG["sitelibdir"]
|
217
|
+
#unless $sitedir
|
218
|
+
# version = CONFIG["MAJOR"] + "." + CONFIG["MINOR"]
|
219
|
+
# $libdir = File.join(CONFIG["libdir"], "ruby", version)
|
220
|
+
#
|
221
|
+
# $sitedir = $:.find {|x| x =~ /site_ruby/ }
|
222
|
+
# if !$sitedir
|
223
|
+
# $sitedir = File.join($libdir, "site_ruby")
|
224
|
+
# elsif $sitedir !~ Regexp.quote(version)
|
225
|
+
# $sitedir = File.join($sitedir, version)
|
226
|
+
# end
|
227
|
+
#end
|
228
|
+
|
229
|
+
$srcdir = CONFIG["srcdir"]
|
230
|
+
$version = CONFIG["MAJOR"]+"."+CONFIG["MINOR"]
|
231
|
+
$libdir = File.join(CONFIG["libdir"], "ruby", $version)
|
232
|
+
$bindir = CONFIG['bindir']
|
233
|
+
$archdir = File.join($libdir, CONFIG["arch"])
|
234
|
+
$sitedir = CONFIG["sitelibdir"]
|
235
|
+
if !$sitedir
|
236
|
+
$sitedir = $:.find {|x| x =~ /site_ruby$/}
|
237
|
+
if !$sitedir
|
238
|
+
$sitedir = File.join($libdir, "site_ruby")
|
239
|
+
elsif $sitedir !~ Regexp.new(Regexp.quote($version))
|
240
|
+
$sitedir = File.join($site_libdir, $version)
|
241
|
+
end
|
242
|
+
end
|
243
|
+
|
244
|
+
# get current dir
|
245
|
+
current_dir = Dir.pwd
|
246
|
+
|
247
|
+
### install lib files
|
248
|
+
|
249
|
+
if FileTest.directory?(PKG_LIB_DIR)
|
250
|
+
|
251
|
+
# change dir to package lib dir
|
252
|
+
Dir.chdir(PKG_LIB_DIR)
|
253
|
+
|
254
|
+
# make lib dirs in ruby sitelibdir
|
255
|
+
makedirs = FileList[*PKG_LIB_MKDIRS].to_a
|
256
|
+
makedirs.each {|f| File::makedirs( File.join( $sitedir, *f.split(/\//) ) ) }
|
257
|
+
|
258
|
+
# deprecated files that should be removed
|
259
|
+
deprecated = FileList[*PKG_LIB_DEPRECATE].to_a
|
260
|
+
|
261
|
+
# files to install in library path
|
262
|
+
files = FileList[*PKG_LIB_FILES].to_a
|
263
|
+
|
264
|
+
# the actual gruntwork
|
265
|
+
File::safe_unlink *deprecated.collect{|f| File.join($sitedir, f.split(/\//))}
|
266
|
+
files.each do |f|
|
267
|
+
File::install(f, File.join($sitedir, *f.split(/\//)), 0644, true)
|
268
|
+
end
|
269
|
+
|
270
|
+
# change dir back
|
271
|
+
Dir.chdir(current_dir)
|
272
|
+
|
273
|
+
end
|
274
|
+
|
275
|
+
### install bin files
|
276
|
+
|
277
|
+
if FileTest.directory?(PKG_BIN_DIR)
|
278
|
+
|
279
|
+
# change dir to package bin dir
|
280
|
+
Dir.chdir(PKG_BIN_DIR)
|
281
|
+
|
282
|
+
is_windows_platform = CONFIG["arch"] =~ /dos|win32/i
|
283
|
+
|
284
|
+
# files to install in bin path
|
285
|
+
files = FileList[*PKG_BIN_FILES].to_a
|
286
|
+
|
287
|
+
# deprecated files that should be removed
|
288
|
+
deprecated = FileList[*PKG_BIN_DEPRECATE].to_a
|
289
|
+
|
290
|
+
# the actual gruntwork
|
291
|
+
File::safe_unlink *deprecated.collect{|f| File.join($bindir, f.split(/\//))}
|
292
|
+
files.each do |f|
|
293
|
+
target = File.join($bindir, *f.split(/\//))
|
294
|
+
File::install(f, target, 0755, true)
|
295
|
+
if is_windows_platform
|
296
|
+
File.open("#{target}.cmd", "w") do |file|
|
297
|
+
file.puts "@ruby #{target} %1 %2 %3 %4 %5 %6 %7 %8 %9"
|
298
|
+
end
|
299
|
+
end
|
300
|
+
end
|
301
|
+
|
302
|
+
# change dir back
|
303
|
+
Dir.chdir(current_dir)
|
304
|
+
|
305
|
+
end
|
306
|
+
=end
|
307
|
+
|
308
|
+
end
|
@@ -0,0 +1,80 @@
|
|
1
|
+
<pre id="example" style="font-size: .9em; line-height: 1.1em;">
|
2
|
+
|
3
|
+
--- %YAML:1.0
|
4
|
+
|
5
|
+
title : Reap
|
6
|
+
name : reap
|
7
|
+
version : 6.0.0
|
8
|
+
status : 'beta'
|
9
|
+
|
10
|
+
author : Thomas Sawyer
|
11
|
+
created : '2004-04-01'
|
12
|
+
email : transfirz@zmail.com
|
13
|
+
homepage : "http://reap.rubyforge.org"
|
14
|
+
|
15
|
+
summary : A Ruby Project Management Assistant
|
16
|
+
|
17
|
+
description: >
|
18
|
+
Reap comprises a set of tasks commonly needed by
|
19
|
+
Ruby package developers/deployers, such as testing,
|
20
|
+
packaging, releasing, etc. You can also use Reap
|
21
|
+
to create your own custom tasks. Reap utilizes a
|
22
|
+
YAML configuration file to harvest common project
|
23
|
+
information, significantly simplifying these chores.
|
24
|
+
|
25
|
+
rubyforge:
|
26
|
+
project : reap
|
27
|
+
username : transami
|
28
|
+
|
29
|
+
install: !!installer
|
30
|
+
template: |
|
31
|
+
bin bin * .
|
32
|
+
lib lib/reap **/* $name/$version
|
33
|
+
|
34
|
+
package: !!package
|
35
|
+
distribute : [ tar.bz2, gem, deb ]
|
36
|
+
dependencies : [ facets ]
|
37
|
+
executables : [ reap, rubytest ]
|
38
|
+
dir: '../DISTRIBUTION'
|
39
|
+
exclude:
|
40
|
+
- dist
|
41
|
+
- dev
|
42
|
+
- scrap
|
43
|
+
- web
|
44
|
+
|
45
|
+
release: !!release
|
46
|
+
host : rubyforge.org
|
47
|
+
username : transami
|
48
|
+
project : reap
|
49
|
+
groupid : 811
|
50
|
+
package : Reap
|
51
|
+
dir : '../DISTRIBUTION'
|
52
|
+
|
53
|
+
publish: !!publish
|
54
|
+
target : rubyforge
|
55
|
+
type : web
|
56
|
+
host : rubyforge.org
|
57
|
+
username : transami
|
58
|
+
dir : web
|
59
|
+
|
60
|
+
rdoc: !!rdoc
|
61
|
+
dir: 'web/doc/api'
|
62
|
+
main: README
|
63
|
+
|
64
|
+
announce: !!announce
|
65
|
+
to : ruby-talk@ruby-lang.org
|
66
|
+
from : &email transfirz@zmail.com
|
67
|
+
domain : unit.rubyforge.org
|
68
|
+
server : smtp.gmail.com
|
69
|
+
port : 587
|
70
|
+
account : *email
|
71
|
+
type : login # cram_md5, plain
|
72
|
+
security : tls # ~, tls, ssl (not working yet)
|
73
|
+
file : doc/LATEST # file contains announcement
|
74
|
+
slogan : REAP THE REWARDS!
|
75
|
+
links : []
|
76
|
+
|
77
|
+
doap: !!doap
|
78
|
+
dir: doc
|
79
|
+
|
80
|
+
</pre>
|
Binary file
|