reap 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (48) hide show
  1. data/ChangeLog +2 -0
  2. data/LICENSE +11 -0
  3. data/README +59 -0
  4. data/Reapfile +85 -0
  5. data/bin/reap +103 -0
  6. data/doc/classes/Reap/AnnounceTask.html +331 -0
  7. data/doc/classes/Reap/ChmodTask.html +278 -0
  8. data/doc/classes/Reap/PackageTask.html +372 -0
  9. data/doc/classes/Reap/PublishTask.html +231 -0
  10. data/doc/classes/Reap/RDocTask.html +254 -0
  11. data/doc/classes/Reap/Runner.html +307 -0
  12. data/doc/classes/Reap/Task.html +390 -0
  13. data/doc/classes/Reap/TemplateTask.html +233 -0
  14. data/doc/classes/Reap/TestTask.html +242 -0
  15. data/doc/classes/Reap.html +184 -0
  16. data/doc/created.rid +1 -0
  17. data/doc/files/LICENSE.html +119 -0
  18. data/doc/files/README.html +194 -0
  19. data/doc/files/lib/reap/reap_rb.html +110 -0
  20. data/doc/files/lib/reap/runner_rb.html +113 -0
  21. data/doc/files/lib/reap/task_rb.html +108 -0
  22. data/doc/files/lib/reap/tasks/announce-task_rb.html +113 -0
  23. data/doc/files/lib/reap/tasks/chmod-task_rb.html +101 -0
  24. data/doc/files/lib/reap/tasks/package-task_rb.html +108 -0
  25. data/doc/files/lib/reap/tasks/publish-task_rb.html +101 -0
  26. data/doc/files/lib/reap/tasks/rdoc-task_rb.html +101 -0
  27. data/doc/files/lib/reap/tasks/template-task_rb.html +108 -0
  28. data/doc/files/lib/reap/tasks/test-task_rb.html +101 -0
  29. data/doc/files/lib/reap/template_rb.html +101 -0
  30. data/doc/fr_class_index.html +36 -0
  31. data/doc/fr_file_index.html +39 -0
  32. data/doc/fr_method_index.html +69 -0
  33. data/doc/index.html +24 -0
  34. data/doc/rdoc-style.css +208 -0
  35. data/lib/reap/reap.rb +11 -0
  36. data/lib/reap/runner.rb +95 -0
  37. data/lib/reap/task.rb +103 -0
  38. data/lib/reap/tasks/announce-task.rb +140 -0
  39. data/lib/reap/tasks/chmod-task.rb +72 -0
  40. data/lib/reap/tasks/package-task.rb +153 -0
  41. data/lib/reap/tasks/publish-task.rb +33 -0
  42. data/lib/reap/tasks/rdoc-task.rb +57 -0
  43. data/lib/reap/tasks/template-task.rb +38 -0
  44. data/lib/reap/tasks/test-task.rb +45 -0
  45. data/lib/reap/template.rb +72 -0
  46. data/setup.rb +1361 -0
  47. data/test/test_require.rb +11 -0
  48. metadata +112 -0
data/ChangeLog ADDED
@@ -0,0 +1,2 @@
1
+ v0.1:
2
+ - Initial Toasting
data/LICENSE ADDED
@@ -0,0 +1,11 @@
1
+ = BUTTERED PANCAKES LICENSE
2
+
3
+ The following stipulations:
4
+
5
+ 1) Butter my panakes
6
+ 2) Don't feed the lawyers
7
+
8
+ Which means:
9
+
10
+ 1) Acknowledge arthor and sources
11
+ 2) Don't sue any one over it
data/README ADDED
@@ -0,0 +1,59 @@
1
+ = Reap
2
+
3
+ User Friendly Project Assitant for Ruby
4
+
5
+ == What's This?
6
+
7
+ Reap is a user friendly project assistant for Ruby developers.
8
+ By organizing your project in a semi-formal manner (the same as setup.rb),
9
+ Reap makes it easy to do the following tasks:
10
+
11
+ * Generate RDocs.
12
+ * Run unit tests.
13
+ * Create Ruby Gem packages.
14
+ * Create standard .tar.gz, tar.bzip2 and/or .zip packages.
15
+ * Publish documents to Rubyforge or other web sites.
16
+ * Preform a traditional install (calls setup.rb).
17
+ * Announce a release to Ruby-talk or other mailing list.
18
+ * Prepare files for distribution (i.e. chmod, tag, etc.).
19
+ * Upload packages (coming soon!).
20
+
21
+ If you have special needs that Reap doesn't accomodate,
22
+ new task are farily easy to create. And we are always
23
+ happy to hear suggestions.
24
+
25
+ == Installation
26
+
27
+ === Gem Install
28
+
29
+ Install the ruby gem as you would any other:
30
+
31
+ <tt>gem install reap</tt>
32
+
33
+ Reap is part of the Ruby clibre project and requires
34
+ supporting calibre libraries, Facets and Carats, so
35
+ they will also be installed.
36
+
37
+ === Manual Install
38
+
39
+ To install manually follw the usiusl setup.eb steps:
40
+
41
+ 1. Download the compressed package.
42
+ 2. Unpack it.
43
+ 3. Change into the unpacked directory.
44
+ 4. run <tt>./setup.rb</tt>
45
+
46
+ You should be good to go.
47
+
48
+ == Status
49
+
50
+ Reap is currently Usable Beta. Most of the tasks
51
+ work very well. Refinement are still coomon though,
52
+ and a few important tasks are still being planned.
53
+
54
+ == Legal
55
+
56
+ Reap
57
+ Copyright(c)2004-2005 Thomas Sawyer
58
+ Ruby License
59
+
data/Reapfile ADDED
@@ -0,0 +1,85 @@
1
+ --- %YAML:1.0
2
+
3
+ TITLE: &title Reap
4
+ NAME: &pkg reap
5
+ VERSION: '0.4.0'
6
+ AUTHOR: Trans Onoma
7
+ EMAIL: transfire@gmail.com
8
+
9
+ HOMEPAGE: "http://calibre.rubyforge.org"
10
+
11
+ SUMMARY: Packaging Assitant for Ruby Developers
12
+
13
+ DESCRIPTION: >
14
+ Reap is a build tool specifically designed for Ruby developers. It operates
15
+ solely from a YAML configuration file so it especially easy to maintian your
16
+ Ruby projects. Reap can run tests, build .tgz, .bzip2 and .zip packages, create
17
+ gem packages, perform manual installs, generate rdocs and publish them to the
18
+ web, etc.
19
+
20
+ RUBYFORGE:
21
+ PROJECT: 'calibre'
22
+ USERNAME: transami
23
+
24
+ TEST:
25
+ FILES:
26
+ - 'test/**/tc_*.rb'
27
+ OPTIONS: ~
28
+
29
+ RDOC:
30
+ TITLE: *title
31
+ DIR: 'doc'
32
+ TEMPLATE: html #ruby-red
33
+ OPTIONS: ['--merge', '--inline-source', '--all']
34
+ MAIN: README
35
+ INCLUDE:
36
+ - 'README'
37
+ - 'LICEN*'
38
+ - 'lib/**/*.rb'
39
+ - 'bin/**/*.rb'
40
+ EXCLUDE: []
41
+
42
+ PACKAGE:
43
+ DIR: pkg
44
+ INCLUDE:
45
+ - 'lib/**/*'
46
+ - 'bin/**/*'
47
+ - 'bench/**/*'
48
+ - 'test/**/*'
49
+ - 'doc/**/*'
50
+ - 'rdoc/**/*'
51
+ - 'pub/**/*'
52
+ - 'demo/**/*'
53
+ - 'samples/**/*'
54
+ - 'examples/**/*'
55
+ - 'setup.rb'
56
+ - '[A-Z]*'
57
+ EXCLUDE:
58
+ - InstalledFiles
59
+ AUTOREQUIRE: 'reap/reap'
60
+ EXECUTABLES: ['reap']
61
+ DEPENDENCIES:
62
+ - facets
63
+ - carats
64
+ GEM: true
65
+ ZIP: true
66
+ GZIP: true
67
+ BZIP2: true
68
+
69
+ ANNOUNCE:
70
+ TO: ruby-talk@ruby-lang.org
71
+ FROM: transfire@gmail.com
72
+ DOMAIN: jupiterzeus.net
73
+ SERVER: smtp.gmail.com
74
+ PORT: 25
75
+ ACCOUNT: transfire@gmail.com
76
+ AUTHTYPE: login #cram_md5 #plain
77
+ FILE: ANN
78
+ SLOGAN: Reap Your Rewards!
79
+ INFO:
80
+ - http://calibre.rubyforge.org
81
+
82
+ CHMOD:
83
+ user: trans
84
+ group: users
85
+
data/bin/reap ADDED
@@ -0,0 +1,103 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require 'getoptlong'
4
+ require 'reap/reap'
5
+
6
+ # dislpay the help information
7
+ def show_help
8
+
9
+ puts <<-HERE
10
+
11
+ reap v#{Reap::VERSION}
12
+
13
+ USAGE: reap [options...] <command> [arguments...]
14
+
15
+ COMMANDS:
16
+
17
+ help
18
+ Displays this help information.
19
+
20
+ HERE
21
+
22
+ Reap::Task.registry.each do |t|
23
+ puts " #{t.task}"
24
+ puts " #{t.desc}\n\n"
25
+ end
26
+
27
+ puts <<-HERE
28
+
29
+ OPTIONS:
30
+
31
+ -v --verbose
32
+ Provides extra verbose processing information.
33
+
34
+ -u --use <file>
35
+ Use the specified configuration file rather than
36
+ the default 'Reapfile'.
37
+
38
+ -p --pretend (NOT YET IMPLEMENTED)
39
+ Pretend, just to see what would happen, but don't
40
+ actually do anything.
41
+
42
+ --version
43
+ Display the current version.
44
+
45
+ --help
46
+ Display this help information.
47
+
48
+ HERE
49
+
50
+ end
51
+
52
+ # START OF EXECUTION
53
+
54
+ opts = GetoptLong.new(
55
+ [ "-v", "--verbose", GetoptLong::NO_ARGUMENT ],
56
+ [ "-p", "--pretend", GetoptLong::NO_ARGUMENT ],
57
+ [ "-d", "--debug", GetoptLong::NO_ARGUMENT ],
58
+ [ "-u", "--use", GetoptLong::REQUIRED_ARGUMENT ],
59
+ [ "--version", GetoptLong::NO_ARGUMENT ],
60
+ [ "--help", GetoptLong::NO_ARGUMENT ]
61
+ )
62
+
63
+ cmd = ARGV[0]
64
+ args = ARGV[1..-1]
65
+ config = nil
66
+
67
+ opts.each do |o, a|
68
+ case o
69
+ when '-v'
70
+ $VERBOSE = true
71
+ when '-p'
72
+ $PRETEND = true
73
+ when '-u'
74
+ config = a
75
+ when '-d'
76
+ $DEBUG = true
77
+ when '--help'
78
+ cmd = 'help'
79
+ when '--version'
80
+ cmd = 'version'
81
+ end
82
+ end
83
+
84
+ cmd = cmd.downcase if cmd
85
+ if cmd == nil or cmd == 'help'
86
+ show_help
87
+ exit 0
88
+ end
89
+ if cmd == 'version'
90
+ puts Reap::VERSION
91
+ exit 0
92
+ end
93
+
94
+ runner = Reap::Runner.new( config )
95
+ if runner.task?( cmd.downcase.to_sym )
96
+ cmd = cmd.to_s.downcase.to_sym
97
+ runner.call( cmd, *args )
98
+ else
99
+ puts "Unknown command. Try 'reap help' for assitance."
100
+ exit 0
101
+ end
102
+
103
+
@@ -0,0 +1,331 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
7
+ <head>
8
+ <title>Class: Reap::AnnounceTask</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <meta http-equiv="Content-Script-Type" content="text/javascript" />
11
+ <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
12
+ <script type="text/javascript">
13
+ // <![CDATA[
14
+
15
+ function popupCode( url ) {
16
+ window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
17
+ }
18
+
19
+ function toggleCode( id ) {
20
+ if ( document.getElementById )
21
+ elem = document.getElementById( id );
22
+ else if ( document.all )
23
+ elem = eval( "document.all." + id );
24
+ else
25
+ return false;
26
+
27
+ elemStyle = elem.style;
28
+
29
+ if ( elemStyle.display != "block" ) {
30
+ elemStyle.display = "block"
31
+ } else {
32
+ elemStyle.display = "none"
33
+ }
34
+
35
+ return true;
36
+ }
37
+
38
+ // Make codeblocks hidden by default
39
+ document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
40
+
41
+ // ]]>
42
+ </script>
43
+
44
+ </head>
45
+ <body>
46
+
47
+
48
+
49
+ <div id="classHeader">
50
+ <table class="header-table">
51
+ <tr class="top-aligned-row">
52
+ <td><strong>Class</strong></td>
53
+ <td class="class-name-in-header">Reap::AnnounceTask</td>
54
+ </tr>
55
+ <tr class="top-aligned-row">
56
+ <td><strong>In:</strong></td>
57
+ <td>
58
+ <a href="../../files/lib/reap/tasks/announce-task_rb.html">
59
+ lib/reap/tasks/announce-task.rb
60
+ </a>
61
+ <br />
62
+ </td>
63
+ </tr>
64
+
65
+ <tr class="top-aligned-row">
66
+ <td><strong>Parent:</strong></td>
67
+ <td>
68
+ <a href="Task.html">
69
+ Task
70
+ </a>
71
+ </td>
72
+ </tr>
73
+ </table>
74
+ </div>
75
+ <!-- banner header -->
76
+
77
+ <div id="bodyContent">
78
+
79
+
80
+
81
+ <div id="contextContent">
82
+
83
+
84
+
85
+ </div>
86
+
87
+ <div id="method-list">
88
+ <h3 class="section-bar">Methods</h3>
89
+
90
+ <div class="name-list">
91
+ <a href="#M000041">desc</a>&nbsp;&nbsp;
92
+ <a href="#M000043">run</a>&nbsp;&nbsp;
93
+ <a href="#M000042">set</a>&nbsp;&nbsp;
94
+ <a href="#M000040">task</a>&nbsp;&nbsp;
95
+ </div>
96
+ </div>
97
+
98
+ </div>
99
+
100
+
101
+ <!-- if includes -->
102
+
103
+ <div id="section">
104
+
105
+
106
+
107
+
108
+
109
+
110
+
111
+
112
+ <!-- if method_list -->
113
+ <div id="methods">
114
+ <h3 class="section-bar">Public Class methods</h3>
115
+
116
+ <div id="method-M000041" class="method-detail">
117
+ <a name="M000041"></a>
118
+
119
+ <div class="method-heading">
120
+ <a href="#M000041" class="method-signature">
121
+ <span class="method-name">desc</span><span class="method-args">()</span>
122
+ </a>
123
+ </div>
124
+
125
+ <div class="method-description">
126
+ <p><a class="source-toggle" href="#"
127
+ onclick="toggleCode('M000041-source');return false;">[Source]</a></p>
128
+ <div class="method-source-code" id="M000041-source">
129
+ <pre>
130
+ <span class="ruby-comment cmt"># File lib/reap/tasks/announce-task.rb, line 15</span>
131
+ <span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">desc</span> ; <span class="ruby-value str">&quot;Sends [ANN] email to ruby-talk or other list.&quot;</span> ; <span class="ruby-keyword kw">end</span>
132
+ </pre>
133
+ </div>
134
+ </div>
135
+ </div>
136
+
137
+ <div id="method-M000040" class="method-detail">
138
+ <a name="M000040"></a>
139
+
140
+ <div class="method-heading">
141
+ <a href="#M000040" class="method-signature">
142
+ <span class="method-name">task</span><span class="method-args">()</span>
143
+ </a>
144
+ </div>
145
+
146
+ <div class="method-description">
147
+ <p><a class="source-toggle" href="#"
148
+ onclick="toggleCode('M000040-source');return false;">[Source]</a></p>
149
+ <div class="method-source-code" id="M000040-source">
150
+ <pre>
151
+ <span class="ruby-comment cmt"># File lib/reap/tasks/announce-task.rb, line 13</span>
152
+ <span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">task</span> ; <span class="ruby-identifier">:announce</span> ; <span class="ruby-keyword kw">end</span>
153
+ </pre>
154
+ </div>
155
+ </div>
156
+ </div>
157
+
158
+ <h3 class="section-bar">Public Instance methods</h3>
159
+
160
+ <div id="method-M000043" class="method-detail">
161
+ <a name="M000043"></a>
162
+
163
+ <div class="method-heading">
164
+ <a href="#M000043" class="method-signature">
165
+ <span class="method-name">run</span><span class="method-args">()</span>
166
+ </a>
167
+ </div>
168
+
169
+ <div class="method-description">
170
+ <p><a class="source-toggle" href="#"
171
+ onclick="toggleCode('M000043-source');return false;">[Source]</a></p>
172
+ <div class="method-source-code" id="M000043-source">
173
+ <pre>
174
+ <span class="ruby-comment cmt"># File lib/reap/tasks/announce-task.rb, line 108</span>
175
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">run</span>
176
+ <span class="ruby-identifier">puts</span> <span class="ruby-node">&quot;\n#{@message}\n\n&quot;</span>
177
+ <span class="ruby-identifier">print</span> <span class="ruby-value str">&quot;Send? [Y/n] &quot;</span>
178
+ <span class="ruby-keyword kw">until</span> <span class="ruby-identifier">inp</span> = <span class="ruby-identifier">$stdin</span>.<span class="ruby-identifier">gets</span>[<span class="ruby-value">0</span>,<span class="ruby-value">1</span>] ; <span class="ruby-identifier">sleep</span> <span class="ruby-value">1</span> ; <span class="ruby-keyword kw">end</span>
179
+ <span class="ruby-keyword kw">if</span> (<span class="ruby-identifier">inp</span> <span class="ruby-operator">||</span> <span class="ruby-value str">'y'</span>).<span class="ruby-identifier">downcase</span> <span class="ruby-operator">==</span> <span class="ruby-value str">'y'</span>
180
+ <span class="ruby-comment cmt"># ask for password</span>
181
+ <span class="ruby-identifier">print</span> <span class="ruby-node">&quot;Password for #{@account}: &quot;</span>
182
+ <span class="ruby-keyword kw">until</span> <span class="ruby-identifier">passwd</span> = <span class="ruby-identifier">$stdin</span>.<span class="ruby-identifier">gets</span>.<span class="ruby-identifier">strip</span> ; <span class="ruby-identifier">sleep</span> <span class="ruby-value">1</span> ; <span class="ruby-keyword kw">end</span>
183
+ <span class="ruby-identifier">mail</span> = <span class="ruby-node">%Q{
184
+ |From: #{@from}
185
+ |To: #{@address}
186
+ |Subject: #{@subject}
187
+ |
188
+ |#{@message}
189
+ }</span>.<span class="ruby-identifier">margin</span>
190
+ <span class="ruby-keyword kw">begin</span>
191
+ <span class="ruby-comment cmt"># --- Send using SMTP object and an adaptor</span>
192
+ <span class="ruby-constant">Net</span><span class="ruby-operator">::</span><span class="ruby-constant">SMTP</span>.<span class="ruby-identifier">start</span>(<span class="ruby-ivar">@server</span>, <span class="ruby-ivar">@port</span>, <span class="ruby-ivar">@domain</span>, <span class="ruby-ivar">@account</span>, <span class="ruby-identifier">passwd</span>, <span class="ruby-ivar">@authtype</span>) <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">s</span><span class="ruby-operator">|</span>
193
+ <span class="ruby-identifier">s</span>.<span class="ruby-identifier">send_message</span> <span class="ruby-identifier">mail</span>, <span class="ruby-ivar">@from</span>, <span class="ruby-ivar">@address</span>
194
+ <span class="ruby-keyword kw">end</span>
195
+ <span class="ruby-identifier">puts</span> <span class="ruby-node">&quot;Email sent successfully to #{@address}.&quot;</span>
196
+ <span class="ruby-keyword kw">rescue</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-identifier">e</span>
197
+ <span class="ruby-identifier">puts</span> <span class="ruby-value str">&quot;Email delivery failed.&quot;</span>
198
+ <span class="ruby-identifier">puts</span> <span class="ruby-identifier">e</span>
199
+ <span class="ruby-keyword kw">end</span>
200
+ <span class="ruby-keyword kw">else</span>
201
+ <span class="ruby-identifier">puts</span> <span class="ruby-value str">&quot;Reap announce task canceled.&quot;</span>
202
+ <span class="ruby-identifier">exit</span> <span class="ruby-value">0</span>
203
+ <span class="ruby-keyword kw">end</span>
204
+ <span class="ruby-keyword kw">end</span>
205
+ </pre>
206
+ </div>
207
+ </div>
208
+ </div>
209
+
210
+ <div id="method-M000042" class="method-detail">
211
+ <a name="M000042"></a>
212
+
213
+ <div class="method-heading">
214
+ <a href="#M000042" class="method-signature">
215
+ <span class="method-name">set</span><span class="method-args">( section )</span>
216
+ </a>
217
+ </div>
218
+
219
+ <div class="method-description">
220
+ <p><a class="source-toggle" href="#"
221
+ onclick="toggleCode('M000042-source');return false;">[Source]</a></p>
222
+ <div class="method-source-code" id="M000042-source">
223
+ <pre>
224
+ <span class="ruby-comment cmt"># File lib/reap/tasks/announce-task.rb, line 18</span>
225
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">set</span>( <span class="ruby-identifier">section</span> )
226
+ <span class="ruby-ivar">@address</span> = <span class="ruby-identifier">section</span>[<span class="ruby-value str">'to'</span>]
227
+ <span class="ruby-ivar">@from</span> = <span class="ruby-identifier">section</span>[<span class="ruby-value str">'from'</span>].<span class="ruby-identifier">to_s</span>
228
+ <span class="ruby-ivar">@server</span> = <span class="ruby-identifier">section</span>[<span class="ruby-value str">'server'</span>].<span class="ruby-identifier">to_s</span>.<span class="ruby-identifier">strip</span>
229
+ <span class="ruby-ivar">@port</span> = <span class="ruby-identifier">section</span>[<span class="ruby-value str">'port'</span>] <span class="ruby-operator">||</span> <span class="ruby-value">25</span>
230
+ <span class="ruby-ivar">@domain</span> = <span class="ruby-identifier">section</span>[<span class="ruby-value str">'domain'</span>].<span class="ruby-identifier">to_s</span>.<span class="ruby-identifier">strip</span>
231
+ <span class="ruby-ivar">@account</span> = <span class="ruby-identifier">section</span>[<span class="ruby-value str">'account'</span>].<span class="ruby-identifier">to_s</span>
232
+ <span class="ruby-ivar">@authtype</span> = <span class="ruby-identifier">section</span>[<span class="ruby-value str">'authtype'</span>].<span class="ruby-identifier">to_sym</span>
233
+ <span class="ruby-ivar">@subject</span> = <span class="ruby-node">&quot;[ANN] #{@config['title']}, v#{@config['version']}&quot;</span>
234
+
235
+ <span class="ruby-comment cmt">#raise &quot;DOMAIN is a required field&quot; if @domain.empty?</span>
236
+
237
+ <span class="ruby-identifier">announce</span> = <span class="ruby-node">%Q{
238
+ |
239
+ |A N N O U N C I N G
240
+ |
241
+ |#{@config['title']}, v#{@config['version']}
242
+ |
243
+ |#{@config['summary']}
244
+ |
245
+ }</span>.<span class="ruby-identifier">margin</span>.<span class="ruby-identifier">center_lines</span>(<span class="ruby-value">66</span>)
246
+
247
+ <span class="ruby-comment cmt"># abstract</span>
248
+ <span class="ruby-identifier">abstract</span> = <span class="ruby-value str">''</span>
249
+ <span class="ruby-identifier">desc</span> = <span class="ruby-ivar">@config</span>[<span class="ruby-value str">'description'</span>]
250
+ <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">desc</span>
251
+ <span class="ruby-identifier">abstract</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n\n&quot;</span>
252
+ <span class="ruby-identifier">abstract</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-node">&quot;ABSTRACT: #{desc}&quot;</span>.<span class="ruby-identifier">word_wrap</span>(<span class="ruby-value">72</span>)
253
+ <span class="ruby-identifier">abstract</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n&quot;</span>
254
+ <span class="ruby-keyword kw">end</span>
255
+
256
+ <span class="ruby-comment cmt"># more info</span>
257
+ <span class="ruby-identifier">info</span> = <span class="ruby-value str">''</span>
258
+ <span class="ruby-identifier">info_arr</span> = <span class="ruby-identifier">section</span>[<span class="ruby-value str">'info'</span>]
259
+ <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">info_arr</span>.<span class="ruby-identifier">empty?</span>
260
+ <span class="ruby-identifier">info</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n&quot;</span>
261
+ <span class="ruby-identifier">info</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;For More Information&quot;</span>.<span class="ruby-identifier">center</span>(<span class="ruby-value">67</span>)
262
+ <span class="ruby-identifier">info</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n&quot;</span>
263
+ <span class="ruby-identifier">info_arr</span>.<span class="ruby-identifier">each</span>{ <span class="ruby-operator">|</span><span class="ruby-identifier">mi</span><span class="ruby-operator">|</span> <span class="ruby-identifier">info</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-node">&quot;#{mi}&quot;</span>.<span class="ruby-identifier">center</span>(<span class="ruby-value">67</span>) }
264
+ <span class="ruby-identifier">info</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n\n&quot;</span>
265
+ <span class="ruby-keyword kw">end</span>
266
+
267
+ <span class="ruby-comment cmt"># slogan</span>
268
+ <span class="ruby-identifier">slogan</span> = <span class="ruby-value str">''</span>
269
+ <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">section</span>[<span class="ruby-value str">'slogan'</span>]
270
+ <span class="ruby-identifier">slogan</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n\n&quot;</span>
271
+ <span class="ruby-identifier">slogan</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">section</span>[<span class="ruby-value str">'slogan'</span>].<span class="ruby-identifier">center</span>(<span class="ruby-value">67</span>)
272
+ <span class="ruby-identifier">slogan</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n\n&quot;</span>
273
+ <span class="ruby-keyword kw">end</span>
274
+
275
+ <span class="ruby-comment cmt"># memo</span>
276
+ <span class="ruby-identifier">memo</span> = <span class="ruby-value str">''</span>
277
+ <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">section</span>[<span class="ruby-value str">'memo'</span>]
278
+ <span class="ruby-identifier">memo</span> = <span class="ruby-value str">''</span>
279
+ <span class="ruby-identifier">memo</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n&quot;</span> <span class="ruby-operator">&lt;&lt;</span> (<span class="ruby-value str">'-'</span> <span class="ruby-operator">*</span> <span class="ruby-value">72</span>) <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n&quot;</span>
280
+ <span class="ruby-identifier">memo</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;(Memo)\n\n&quot;</span>
281
+ <span class="ruby-identifier">memo</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">section</span>[<span class="ruby-value str">'memo'</span>].<span class="ruby-identifier">clump</span>.<span class="ruby-identifier">word_wrap</span>(<span class="ruby-value">72</span>)
282
+ <span class="ruby-comment cmt">#memo &lt;&lt; &quot;\n&quot;</span>
283
+ <span class="ruby-keyword kw">end</span>
284
+
285
+ <span class="ruby-comment cmt"># msg file</span>
286
+ <span class="ruby-identifier">msg</span> = <span class="ruby-value str">''</span>
287
+ <span class="ruby-identifier">msg_file</span> = <span class="ruby-identifier">section</span>[<span class="ruby-value str">'file'</span>]
288
+ <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">msg_file</span> <span class="ruby-keyword kw">and</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">file?</span>( <span class="ruby-identifier">msg_file</span> )
289
+ <span class="ruby-identifier">msg</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n&quot;</span> <span class="ruby-operator">&lt;&lt;</span> (<span class="ruby-value str">&quot;-&quot;</span> <span class="ruby-operator">*</span> <span class="ruby-value">72</span>) <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n&quot;</span>
290
+ <span class="ruby-identifier">msg</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-node">&quot;(from #{msg_file})\n\n&quot;</span>
291
+ <span class="ruby-identifier">mg</span> = <span class="ruby-value str">''</span>
292
+ <span class="ruby-constant">File</span>.<span class="ruby-identifier">open</span>( <span class="ruby-identifier">msg_file</span> ) { <span class="ruby-operator">|</span><span class="ruby-identifier">f</span><span class="ruby-operator">|</span> <span class="ruby-identifier">mg</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">f</span>.<span class="ruby-identifier">gets</span>(<span class="ruby-keyword kw">nil</span>) }
293
+ <span class="ruby-identifier">msg</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">mg</span>.<span class="ruby-identifier">clump</span>.<span class="ruby-identifier">word_wrap</span>(<span class="ruby-value">72</span>)
294
+ <span class="ruby-keyword kw">end</span>
295
+
296
+ <span class="ruby-comment cmt"># stamp</span>
297
+ <span class="ruby-identifier">stamp</span> = <span class="ruby-value str">''</span>
298
+ <span class="ruby-identifier">stamp</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n&quot;</span> <span class="ruby-operator">&lt;&lt;</span> (<span class="ruby-value str">&quot;-&quot;</span> <span class="ruby-operator">*</span> <span class="ruby-value">72</span>) <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n&quot;</span>
299
+ <span class="ruby-identifier">stamp</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">%Q{
300
+ |Generated by Reap, a dedicated Ruby Packaging Assistant.
301
+ |Do you Ruby? (http://www.ruby-lang.org)
302
+ }</span>.<span class="ruby-identifier">margin</span>
303
+ <span class="ruby-identifier">stamp</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value str">&quot;\n\n&quot;</span>
304
+
305
+ <span class="ruby-ivar">@message</span> = <span class="ruby-value str">''</span>
306
+ <span class="ruby-ivar">@message</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">announce</span>
307
+ <span class="ruby-ivar">@message</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">abstract</span>
308
+ <span class="ruby-ivar">@message</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">info</span>
309
+ <span class="ruby-ivar">@message</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">slogan</span>
310
+ <span class="ruby-ivar">@message</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">memo</span>
311
+ <span class="ruby-ivar">@message</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">msg</span>
312
+ <span class="ruby-ivar">@message</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">stamp</span>
313
+ <span class="ruby-keyword kw">end</span>
314
+ </pre>
315
+ </div>
316
+ </div>
317
+ </div>
318
+
319
+
320
+ </div>
321
+
322
+
323
+ </div>
324
+
325
+
326
+ <div id="validator-badges">
327
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
328
+ </div>
329
+
330
+ </body>
331
+ </html>