backpack 0.1.0 → 0.2.0

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/README CHANGED
@@ -9,3 +9,52 @@ Copyright (C) 2008 Gregoire Lejeune
9
9
  == DESCRIPTION:
10
10
 
11
11
  Backpack is a simple plugin generator for bivouac[http://bivouac.rubyforge.org].
12
+
13
+ == FEATURES/PROBLEMS:
14
+
15
+ === 0.2.0:
16
+
17
+ * Major bug correction in plugin_generator.rb, template_controller.rb and template_view.rb
18
+
19
+ === 0.1.0:
20
+
21
+ * First public release
22
+
23
+ == USAGE:
24
+
25
+ Usage: backpack [options] plugin_name
26
+ backpack is a plugin generator for bivouac
27
+
28
+ Specific options:
29
+ -g, --generator NAME:TYPE,... Generator list. TYPE must be 'view' or 'controller'
30
+ -c, --no-controller-helpers Do not create controller helper
31
+ -v, --no-view-helpers Do not create view helper
32
+
33
+ Common options:
34
+ -?, --help Show this message
35
+ -V, --version Show version
36
+
37
+ == EXAMPLE:
38
+
39
+ backpack -g hello:view,world:controller "Test's Tent"
40
+ create /Users/greg/temp/test_s_tent
41
+ create /Users/greg/temp/test_s_tent/copy_on_install
42
+ create /Users/greg/temp/test_s_tent/copy_on_install/public
43
+ create /Users/greg/temp/test_s_tent/copy_on_install/public/images
44
+ create /Users/greg/temp/test_s_tent/copy_on_install/public/javascripts
45
+ create /Users/greg/temp/test_s_tent/copy_on_install/public/stylesheets
46
+ create /Users/greg/temp/test_s_tent/tasks
47
+ create /Users/greg/temp/test_s_tent/README
48
+ create /Users/greg/temp/test_s_tent/INSTALL
49
+ create /Users/greg/temp/test_s_tent/LICENCE
50
+ create /Users/greg/temp/test_s_tent/tasks/test_s_tent.rake
51
+ create /Users/greg/temp/test_s_tent/generators
52
+ create /Users/greg/temp/test_s_tent/generators/test_s_tent.rb
53
+ create /Users/greg/temp/test_s_tent/generators/template
54
+ create /Users/greg/temp/test_s_tent/generators/template/hello_view.rb
55
+ create /Users/greg/temp/test_s_tent/generators/template/world_controller.rb
56
+ create /Users/greg/temp/test_s_tent/lib
57
+ create /Users/greg/temp/test_s_tent/lib/test_s_tent
58
+ create /Users/greg/temp/test_s_tent/init.rb
59
+ create /Users/greg/temp/test_s_tent/lib/test_s_tent/view_helpers.rb
60
+ create /Users/greg/temp/test_s_tent/lib/test_s_tent/controller_helpers.rb
@@ -0,0 +1 @@
1
+ Thu, 10 Apr 2008 10:19:38 +0200
@@ -0,0 +1,95 @@
1
+
2
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
3
+ <html>
4
+ <head>
5
+ <title>
6
+ Backpack, the Documentation &raquo; File: AUTHORS
7
+ </title>
8
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
9
+ <link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
10
+ <script language="JavaScript" type="text/javascript">
11
+ // <![CDATA[
12
+
13
+ function toggleSource( id )
14
+ {
15
+ var elem
16
+ var link
17
+
18
+ if( document.getElementById )
19
+ {
20
+ elem = document.getElementById( id )
21
+ link = document.getElementById( "l_" + id )
22
+ }
23
+ else if ( document.all )
24
+ {
25
+ elem = eval( "document.all." + id )
26
+ link = eval( "document.all.l_" + id )
27
+ }
28
+ else
29
+ return false;
30
+
31
+ if( elem.style.display == "block" )
32
+ {
33
+ elem.style.display = "none"
34
+ link.innerHTML = "show source"
35
+ }
36
+ else
37
+ {
38
+ elem.style.display = "block"
39
+ link.innerHTML = "hide source"
40
+ }
41
+ }
42
+
43
+ function openCode( url )
44
+ {
45
+ window.open( url, "SOURCE_CODE", "width=400,height=400,scrollbars=yes" )
46
+ }
47
+ // ]]>
48
+ </script>
49
+ </head>
50
+ <body>
51
+ <!--
52
+ <div id="menu">
53
+ <h3 class="title">File: AUTHORS</h3>
54
+ </div>
55
+ -->
56
+ <div id="fullpage">
57
+ <div id="pager">
58
+ <table>
59
+ <tr><td><img src="../rubyfr.png" /></td>
60
+ <td id="pagertd">
61
+ <strong># File: AUTHORS<br />
62
+ [
63
+ "<a href="../files/README.html" value="File: README">README</a>",
64
+ "<a href="../files/AUTHORS.html" value="File: AUTHORS">AUTHORS</a>",
65
+ "<a href="../files/COPYING.html" value="File: COPYING">COPYING</a>",
66
+ <a href="http://greg.rubyfr.net">nil</a>].each do<br />
67
+ end</strong>
68
+ </td></tr>
69
+ </table>
70
+ </ul>
71
+ </div>
72
+
73
+ <div id="AUTHORS" class="page_shade">
74
+ <div class="page">
75
+ <div class="header">
76
+ <div class="path">AUTHORS / Wed Apr 09 14:54:34 +0200 2008</div>
77
+ </div>
78
+
79
+ <p>
80
+ Gregoire Lejeune &lt;glejeune.lejeune@free.fr&gt;
81
+ </p>
82
+
83
+
84
+
85
+
86
+
87
+
88
+
89
+ </div>
90
+ </div>
91
+
92
+
93
+ </div>
94
+ </body>
95
+ </html>
@@ -0,0 +1,519 @@
1
+
2
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
3
+ <html>
4
+ <head>
5
+ <title>
6
+ Backpack, the Documentation &raquo; File: COPYING
7
+ </title>
8
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
9
+ <link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
10
+ <script language="JavaScript" type="text/javascript">
11
+ // <![CDATA[
12
+
13
+ function toggleSource( id )
14
+ {
15
+ var elem
16
+ var link
17
+
18
+ if( document.getElementById )
19
+ {
20
+ elem = document.getElementById( id )
21
+ link = document.getElementById( "l_" + id )
22
+ }
23
+ else if ( document.all )
24
+ {
25
+ elem = eval( "document.all." + id )
26
+ link = eval( "document.all.l_" + id )
27
+ }
28
+ else
29
+ return false;
30
+
31
+ if( elem.style.display == "block" )
32
+ {
33
+ elem.style.display = "none"
34
+ link.innerHTML = "show source"
35
+ }
36
+ else
37
+ {
38
+ elem.style.display = "block"
39
+ link.innerHTML = "hide source"
40
+ }
41
+ }
42
+
43
+ function openCode( url )
44
+ {
45
+ window.open( url, "SOURCE_CODE", "width=400,height=400,scrollbars=yes" )
46
+ }
47
+ // ]]>
48
+ </script>
49
+ </head>
50
+ <body>
51
+ <!--
52
+ <div id="menu">
53
+ <h3 class="title">File: COPYING</h3>
54
+ </div>
55
+ -->
56
+ <div id="fullpage">
57
+ <div id="pager">
58
+ <table>
59
+ <tr><td><img src="../rubyfr.png" /></td>
60
+ <td id="pagertd">
61
+ <strong># File: COPYING<br />
62
+ [
63
+ "<a href="../files/README.html" value="File: README">README</a>",
64
+ "<a href="../files/AUTHORS.html" value="File: AUTHORS">AUTHORS</a>",
65
+ "<a href="../files/COPYING.html" value="File: COPYING">COPYING</a>",
66
+ <a href="http://greg.rubyfr.net">nil</a>].each do<br />
67
+ end</strong>
68
+ </td></tr>
69
+ </table>
70
+ </ul>
71
+ </div>
72
+
73
+ <div id="COPYING" class="page_shade">
74
+ <div class="page">
75
+ <div class="header">
76
+ <div class="path">COPYING / Wed Apr 09 14:54:54 +0200 2008</div>
77
+ </div>
78
+
79
+ <pre>
80
+ GNU GENERAL PUBLIC LICENSE
81
+ Version 2, June 1991
82
+
83
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.
84
+ 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
85
+ Everyone is permitted to copy and distribute verbatim copies
86
+ of this license document, but changing it is not allowed.
87
+
88
+ Preamble
89
+
90
+ The licenses for most software are designed to take away your
91
+ </pre>
92
+ <p>
93
+ freedom to share and change it. By contrast, the GNU General Public License
94
+ is intended to guarantee your freedom to share and change free
95
+ software&#8212;to make sure the software is free for all its users. This
96
+ General Public License applies to most of the Free Software
97
+ Foundation&#8216;s software and to any other program whose authors commit
98
+ to using it. (Some other Free Software Foundation software is covered by
99
+ the GNU Library General Public License instead.) You can apply it to your
100
+ programs, too.
101
+ </p>
102
+ <pre>
103
+ When we speak of free software, we are referring to freedom, not
104
+ </pre>
105
+ <p>
106
+ price. Our General Public Licenses are designed to make sure that you have
107
+ the freedom to distribute copies of free software (and charge for this
108
+ service if you wish), that you receive source code or can get it if you
109
+ want it, that you can change the software or use pieces of it in new free
110
+ programs; and that you know you can do these things.
111
+ </p>
112
+ <pre>
113
+ To protect your rights, we need to make restrictions that forbid
114
+ </pre>
115
+ <p>
116
+ anyone to deny you these rights or to ask you to surrender the rights.
117
+ These restrictions translate to certain responsibilities for you if you
118
+ distribute copies of the software, or if you modify it.
119
+ </p>
120
+ <pre>
121
+ For example, if you distribute copies of such a program, whether
122
+ </pre>
123
+ <p>
124
+ gratis or for a fee, you must give the recipients all the rights that you
125
+ have. You must make sure that they, too, receive or can get the source
126
+ code. And you must show them these terms so they know their rights.
127
+ </p>
128
+ <pre>
129
+ We protect your rights with two steps: (1) copyright the software, and
130
+ </pre>
131
+ <p>
132
+ (2) offer you this license which gives you legal permission to copy,
133
+ distribute and/or modify the software.
134
+ </p>
135
+ <pre>
136
+ Also, for each author's protection and ours, we want to make certain
137
+ </pre>
138
+ <p>
139
+ that everyone understands that there is no warranty for this free software.
140
+ If the software is modified by someone else and passed on, we want its
141
+ recipients to know that what they have is not the original, so that any
142
+ problems introduced by others will not reflect on the original
143
+ authors&#8217; reputations.
144
+ </p>
145
+ <pre>
146
+ Finally, any free program is threatened constantly by software
147
+ </pre>
148
+ <p>
149
+ patents. We wish to avoid the danger that redistributors of a free program
150
+ will individually obtain patent licenses, in effect making the program
151
+ proprietary. To prevent this, we have made it clear that any patent must be
152
+ licensed for everyone&#8216;s free use or not licensed at all.
153
+ </p>
154
+ <pre>
155
+ The precise terms and conditions for copying, distribution and
156
+ </pre>
157
+ <p>
158
+ modification follow.
159
+ </p>
160
+ <pre>
161
+ GNU GENERAL PUBLIC LICENSE
162
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
163
+
164
+ 0. This License applies to any program or other work which contains
165
+ </pre>
166
+ <p>
167
+ a notice placed by the copyright holder saying it may be distributed under
168
+ the terms of this General Public License. The &quot;Program&quot;, below,
169
+ refers to any such program or work, and a &quot;work based on the
170
+ Program&quot; means either the Program or any derivative work under
171
+ copyright law: that is to say, a work containing the Program or a portion
172
+ of it, either verbatim or with modifications and/or translated into another
173
+ language. (Hereinafter, translation is included without limitation in the
174
+ term &quot;modification&quot;.) Each licensee is addressed as
175
+ &quot;you&quot;.
176
+ </p>
177
+ <p>
178
+ Activities other than copying, distribution and modification are not
179
+ covered by this License; they are outside its scope. The act of running the
180
+ Program is not restricted, and the output from the Program is covered only
181
+ if its contents constitute a work based on the Program (independent of
182
+ having been made by running the Program). Whether that is true depends on
183
+ what the Program does.
184
+ </p>
185
+ <pre>
186
+ 1. You may copy and distribute verbatim copies of the Program's
187
+ </pre>
188
+ <p>
189
+ source code as you receive it, in any medium, provided that you
190
+ conspicuously and appropriately publish on each copy an appropriate
191
+ copyright notice and disclaimer of warranty; keep intact all the notices
192
+ that refer to this License and to the absence of any warranty; and give any
193
+ other recipients of the Program a copy of this License along with the
194
+ Program.
195
+ </p>
196
+ <p>
197
+ You may charge a fee for the physical act of transferring a copy, and you
198
+ may at your option offer warranty protection in exchange for a fee.
199
+ </p>
200
+ <pre>
201
+ 2. You may modify your copy or copies of the Program or any portion
202
+ </pre>
203
+ <p>
204
+ of it, thus forming a work based on the Program, and copy and distribute
205
+ such modifications or work under the terms of Section 1 above, provided
206
+ that you also meet all of these conditions:
207
+ </p>
208
+ <pre>
209
+ a) You must cause the modified files to carry prominent notices
210
+ stating that you changed the files and the date of any change.
211
+
212
+ b) You must cause any work that you distribute or publish, that in
213
+ whole or in part contains or is derived from the Program or any
214
+ part thereof, to be licensed as a whole at no charge to all third
215
+ parties under the terms of this License.
216
+
217
+ c) If the modified program normally reads commands interactively
218
+ when run, you must cause it, when started running for such
219
+ interactive use in the most ordinary way, to print or display an
220
+ announcement including an appropriate copyright notice and a
221
+ notice that there is no warranty (or else, saying that you provide
222
+ a warranty) and that users may redistribute the program under
223
+ these conditions, and telling the user how to view a copy of this
224
+ License. (Exception: if the Program itself is interactive but
225
+ does not normally print such an announcement, your work based on
226
+ the Program is not required to print an announcement.)
227
+ </pre>
228
+ <p>
229
+ These requirements apply to the modified work as a whole. If identifiable
230
+ sections of that work are not derived from the Program, and can be
231
+ reasonably considered independent and separate works in themselves, then
232
+ this License, and its terms, do not apply to those sections when you
233
+ distribute them as separate works. But when you distribute the same
234
+ sections as part of a whole which is a work based on the Program, the
235
+ distribution of the whole must be on the terms of this License, whose
236
+ permissions for other licensees extend to the entire whole, and thus to
237
+ each and every part regardless of who wrote it.
238
+ </p>
239
+ <p>
240
+ Thus, it is not the intent of this section to claim rights or contest your
241
+ rights to work written entirely by you; rather, the intent is to exercise
242
+ the right to control the distribution of derivative or collective works
243
+ based on the Program.
244
+ </p>
245
+ <p>
246
+ In addition, mere aggregation of another work not based on the Program with
247
+ the Program (or with a work based on the Program) on a volume of a storage
248
+ or distribution medium does not bring the other work under the scope of
249
+ this License.
250
+ </p>
251
+ <pre>
252
+ 3. You may copy and distribute the Program (or a work based on it,
253
+ </pre>
254
+ <p>
255
+ under Section 2) in object code or executable form under the terms of
256
+ Sections 1 and 2 above provided that you also do one of the following:
257
+ </p>
258
+ <pre>
259
+ a) Accompany it with the complete corresponding machine-readable
260
+ source code, which must be distributed under the terms of Sections
261
+ 1 and 2 above on a medium customarily used for software interchange; or,
262
+
263
+ b) Accompany it with a written offer, valid for at least three
264
+ years, to give any third party, for a charge no more than your
265
+ cost of physically performing source distribution, a complete
266
+ machine-readable copy of the corresponding source code, to be
267
+ distributed under the terms of Sections 1 and 2 above on a medium
268
+ customarily used for software interchange; or,
269
+
270
+ c) Accompany it with the information you received as to the offer
271
+ to distribute corresponding source code. (This alternative is
272
+ allowed only for noncommercial distribution and only if you
273
+ received the program in object code or executable form with such
274
+ an offer, in accord with Subsection b above.)
275
+ </pre>
276
+ <p>
277
+ The source code for a work means the preferred form of the work for making
278
+ modifications to it. For an executable work, complete source code means all
279
+ the source code for all modules it contains, plus any associated interface
280
+ definition files, plus the scripts used to control compilation and
281
+ installation of the executable. However, as a special exception, the source
282
+ code distributed need not include anything that is normally distributed (in
283
+ either source or binary form) with the major components (compiler, kernel,
284
+ and so on) of the operating system on which the executable runs, unless
285
+ that component itself accompanies the executable.
286
+ </p>
287
+ <p>
288
+ If distribution of executable or object code is made by offering access to
289
+ copy from a designated place, then offering equivalent access to copy the
290
+ source code from the same place counts as distribution of the source code,
291
+ even though third parties are not compelled to copy the source along with
292
+ the object code.
293
+ </p>
294
+ <pre>
295
+ 4. You may not copy, modify, sublicense, or distribute the Program
296
+ </pre>
297
+ <p>
298
+ except as expressly provided under this License. Any attempt otherwise to
299
+ copy, modify, sublicense or distribute the Program is void, and will
300
+ automatically terminate your rights under this License. However, parties
301
+ who have received copies, or rights, from you under this License will not
302
+ have their licenses terminated so long as such parties remain in full
303
+ compliance.
304
+ </p>
305
+ <pre>
306
+ 5. You are not required to accept this License, since you have not
307
+ </pre>
308
+ <p>
309
+ signed it. However, nothing else grants you permission to modify or
310
+ distribute the Program or its derivative works. These actions are
311
+ prohibited by law if you do not accept this License. Therefore, by
312
+ modifying or distributing the Program (or any work based on the Program),
313
+ you indicate your acceptance of this License to do so, and all its terms
314
+ and conditions for copying, distributing or modifying the Program or works
315
+ based on it.
316
+ </p>
317
+ <pre>
318
+ 6. Each time you redistribute the Program (or any work based on the
319
+ </pre>
320
+ <p>
321
+ Program), the recipient automatically receives a license from the original
322
+ licensor to copy, distribute or modify the Program subject to these terms
323
+ and conditions. You may not impose any further restrictions on the
324
+ recipients&#8217; exercise of the rights granted herein. You are not
325
+ responsible for enforcing compliance by third parties to this License.
326
+ </p>
327
+ <pre>
328
+ 7. If, as a consequence of a court judgment or allegation of patent
329
+ </pre>
330
+ <p>
331
+ infringement or for any other reason (not limited to patent issues),
332
+ conditions are imposed on you (whether by court order, agreement or
333
+ otherwise) that contradict the conditions of this License, they do not
334
+ excuse you from the conditions of this License. If you cannot distribute so
335
+ as to satisfy simultaneously your obligations under this License and any
336
+ other pertinent obligations, then as a consequence you may not distribute
337
+ the Program at all. For example, if a patent license would not permit
338
+ royalty-free redistribution of the Program by all those who receive copies
339
+ directly or indirectly through you, then the only way you could satisfy
340
+ both it and this License would be to refrain entirely from distribution of
341
+ the Program.
342
+ </p>
343
+ <p>
344
+ If any portion of this section is held invalid or unenforceable under any
345
+ particular circumstance, the balance of the section is intended to apply
346
+ and the section as a whole is intended to apply in other circumstances.
347
+ </p>
348
+ <p>
349
+ It is not the purpose of this section to induce you to infringe any patents
350
+ or other property right claims or to contest validity of any such claims;
351
+ this section has the sole purpose of protecting the integrity of the free
352
+ software distribution system, which is implemented by public license
353
+ practices. Many people have made generous contributions to the wide range
354
+ of software distributed through that system in reliance on consistent
355
+ application of that system; it is up to the author/donor to decide if he or
356
+ she is willing to distribute software through any other system and a
357
+ licensee cannot impose that choice.
358
+ </p>
359
+ <p>
360
+ This section is intended to make thoroughly clear what is believed to be a
361
+ consequence of the rest of this License.
362
+ </p>
363
+ <pre>
364
+ 8. If the distribution and/or use of the Program is restricted in
365
+ </pre>
366
+ <p>
367
+ certain countries either by patents or by copyrighted interfaces, the
368
+ original copyright holder who places the Program under this License may add
369
+ an explicit geographical distribution limitation excluding those countries,
370
+ so that distribution is permitted only in or among countries not thus
371
+ excluded. In such case, this License incorporates the limitation as if
372
+ written in the body of this License.
373
+ </p>
374
+ <pre>
375
+ 9. The Free Software Foundation may publish revised and/or new versions
376
+ </pre>
377
+ <p>
378
+ of the General Public License from time to time. Such new versions will be
379
+ similar in spirit to the present version, but may differ in detail to
380
+ address new problems or concerns.
381
+ </p>
382
+ <p>
383
+ Each version is given a distinguishing version number. If the Program
384
+ specifies a version number of this License which applies to it and
385
+ &quot;any later version&quot;, you have the option of following the terms
386
+ and conditions either of that version or of any later version published by
387
+ the Free Software Foundation. If the Program does not specify a version
388
+ number of this License, you may choose any version ever published by the
389
+ Free Software Foundation.
390
+ </p>
391
+ <pre>
392
+ 10. If you wish to incorporate parts of the Program into other free
393
+ </pre>
394
+ <p>
395
+ programs whose distribution conditions are different, write to the author
396
+ to ask for permission. For software which is copyrighted by the Free
397
+ Software Foundation, write to the Free Software Foundation; we sometimes
398
+ make exceptions for this. Our decision will be guided by the two goals of
399
+ preserving the free status of all derivatives of our free software and of
400
+ promoting the sharing and reuse of software generally.
401
+ </p>
402
+ <pre>
403
+ NO WARRANTY
404
+
405
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
406
+ </pre>
407
+ <p>
408
+ FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
409
+ OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
410
+ PROVIDE THE PROGRAM &quot;AS IS&quot; WITHOUT WARRANTY OF ANY KIND, EITHER
411
+ EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
412
+ OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
413
+ TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
414
+ PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
415
+ REPAIR OR CORRECTION.
416
+ </p>
417
+ <pre>
418
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
419
+ </pre>
420
+ <p>
421
+ WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
422
+ REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
423
+ INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
424
+ OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
425
+ TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
426
+ YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
427
+ PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
428
+ POSSIBILITY OF SUCH DAMAGES.
429
+ </p>
430
+ <pre>
431
+ END OF TERMS AND CONDITIONS
432
+
433
+ How to Apply These Terms to Your New Programs
434
+
435
+ If you develop a new program, and you want it to be of the greatest
436
+ </pre>
437
+ <p>
438
+ possible use to the public, the best way to achieve this is to make it free
439
+ software which everyone can redistribute and change under these terms.
440
+ </p>
441
+ <pre>
442
+ To do so, attach the following notices to the program. It is safest
443
+ </pre>
444
+ <p>
445
+ to attach them to the start of each source file to most effectively convey
446
+ the exclusion of warranty; and each file should have at least the
447
+ &quot;copyright&quot; line and a pointer to where the full notice is found.
448
+ </p>
449
+ <pre>
450
+ &lt;one line to give the program's name and a brief idea of what it does.&gt;
451
+ Copyright (C) &lt;year&gt; &lt;name of author&gt;
452
+
453
+ This program is free software; you can redistribute it and/or modify
454
+ it under the terms of the GNU General Public License as published by
455
+ the Free Software Foundation; either version 2 of the License, or
456
+ (at your option) any later version.
457
+
458
+ This program is distributed in the hope that it will be useful,
459
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
460
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
461
+ GNU General Public License for more details.
462
+
463
+ You should have received a copy of the GNU General Public License
464
+ along with this program; if not, write to the Free Software
465
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
466
+ </pre>
467
+ <p>
468
+ Also add information on how to contact you by electronic and paper mail.
469
+ </p>
470
+ <p>
471
+ If the program is interactive, make it output a short notice like this when
472
+ it starts in an interactive mode:
473
+ </p>
474
+ <pre>
475
+ Gnomovision version 69, Copyright (C) year name of author
476
+ Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
477
+ This is free software, and you are welcome to redistribute it
478
+ under certain conditions; type `show c' for details.
479
+ </pre>
480
+ <p>
481
+ The hypothetical commands `show w&#8217; and `show c&#8217; should show the
482
+ appropriate parts of the General Public License. Of course, the commands
483
+ you use may be called something other than `show w&#8217; and `show
484
+ c&#8217;; they could even be mouse-clicks or menu items&#8212;whatever
485
+ suits your program.
486
+ </p>
487
+ <p>
488
+ You should also get your employer (if you work as a programmer) or your
489
+ school, if any, to sign a &quot;copyright disclaimer&quot; for the program,
490
+ if necessary. Here is a sample; alter the names:
491
+ </p>
492
+ <pre>
493
+ Yoyodyne, Inc., hereby disclaims all copyright interest in the program
494
+ `Gnomovision' (which makes passes at compilers) written by James Hacker.
495
+
496
+ &lt;signature of Ty Coon&gt;, 1 April 1989
497
+ Ty Coon, President of Vice
498
+ </pre>
499
+ <p>
500
+ This General Public License does not permit incorporating your program into
501
+ proprietary programs. If your program is a subroutine library, you may
502
+ consider it more useful to permit linking proprietary applications with the
503
+ library. If this is what you want to do, use the GNU Library General Public
504
+ License instead of this License.
505
+ </p>
506
+
507
+
508
+
509
+
510
+
511
+
512
+
513
+ </div>
514
+ </div>
515
+
516
+
517
+ </div>
518
+ </body>
519
+ </html>
@@ -0,0 +1,166 @@
1
+
2
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
3
+ <html>
4
+ <head>
5
+ <title>
6
+ Backpack, the Documentation &raquo; File: README
7
+ </title>
8
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
9
+ <link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
10
+ <script language="JavaScript" type="text/javascript">
11
+ // <![CDATA[
12
+
13
+ function toggleSource( id )
14
+ {
15
+ var elem
16
+ var link
17
+
18
+ if( document.getElementById )
19
+ {
20
+ elem = document.getElementById( id )
21
+ link = document.getElementById( "l_" + id )
22
+ }
23
+ else if ( document.all )
24
+ {
25
+ elem = eval( "document.all." + id )
26
+ link = eval( "document.all.l_" + id )
27
+ }
28
+ else
29
+ return false;
30
+
31
+ if( elem.style.display == "block" )
32
+ {
33
+ elem.style.display = "none"
34
+ link.innerHTML = "show source"
35
+ }
36
+ else
37
+ {
38
+ elem.style.display = "block"
39
+ link.innerHTML = "hide source"
40
+ }
41
+ }
42
+
43
+ function openCode( url )
44
+ {
45
+ window.open( url, "SOURCE_CODE", "width=400,height=400,scrollbars=yes" )
46
+ }
47
+ // ]]>
48
+ </script>
49
+ </head>
50
+ <body>
51
+ <!--
52
+ <div id="menu">
53
+ <h3 class="title">File: README</h3>
54
+ </div>
55
+ -->
56
+ <div id="fullpage">
57
+ <div id="pager">
58
+ <table>
59
+ <tr><td><img src="../rubyfr.png" /></td>
60
+ <td id="pagertd">
61
+ <strong># File: README<br />
62
+ [
63
+ "<a href="../files/README.html" value="File: README">README</a>",
64
+ "<a href="../files/AUTHORS.html" value="File: AUTHORS">AUTHORS</a>",
65
+ "<a href="../files/COPYING.html" value="File: COPYING">COPYING</a>",
66
+ <a href="http://greg.rubyfr.net">nil</a>].each do<br />
67
+ end</strong>
68
+ </td></tr>
69
+ </table>
70
+ </ul>
71
+ </div>
72
+
73
+ <div id="README" class="page_shade">
74
+ <div class="page">
75
+ <div class="header">
76
+ <div class="path">README / Thu Apr 10 10:19:33 +0200 2008</div>
77
+ </div>
78
+
79
+ <h1>Backpack</h1>
80
+ <p>
81
+ Copyright (C) 2008 Gregoire Lejeune
82
+ </p>
83
+ <ul>
84
+ <li><a href="http://bivouac.rubyforge.org">bivouac.rubyforge.org</a>/
85
+
86
+ </li>
87
+ <li><a
88
+ href="http://rubyforge.org/projects/bivouac">rubyforge.org/projects/bivouac</a>/
89
+
90
+ </li>
91
+ <li><a href="http://greg.rubyfr.net">greg.rubyfr.net</a>
92
+
93
+ </li>
94
+ </ul>
95
+ <h2>DESCRIPTION:</h2>
96
+ <p>
97
+ Backpack is a simple plugin generator for <a
98
+ href="http://bivouac.rubyforge.org">bivouac</a>.
99
+ </p>
100
+ <h2>FEATURES/PROBLEMS:</h2>
101
+ <h3>0.2.0:</h3>
102
+ <ul>
103
+ <li>Major bug correction in plugin_generator.rb, template_controller.rb and
104
+ template_view.rb
105
+
106
+ </li>
107
+ </ul>
108
+ <h3>0.1.0:</h3>
109
+ <ul>
110
+ <li>First public release
111
+
112
+ </li>
113
+ </ul>
114
+ <h2>USAGE:</h2>
115
+ <pre>
116
+ Usage: backpack [options] plugin_name
117
+ backpack is a plugin generator for bivouac
118
+
119
+ Specific options:
120
+ -g, --generator NAME:TYPE,... Generator list. TYPE must be 'view' or 'controller'
121
+ -c, --no-controller-helpers Do not create controller helper
122
+ -v, --no-view-helpers Do not create view helper
123
+
124
+ Common options:
125
+ -?, --help Show this message
126
+ -V, --version Show version
127
+ </pre>
128
+ <h2>EXAMPLE:</h2>
129
+ <pre>
130
+ backpack -g hello:view,world:controller &quot;Test's Tent&quot;
131
+ create /Users/greg/temp/test_s_tent
132
+ create /Users/greg/temp/test_s_tent/copy_on_install
133
+ create /Users/greg/temp/test_s_tent/copy_on_install/public
134
+ create /Users/greg/temp/test_s_tent/copy_on_install/public/images
135
+ create /Users/greg/temp/test_s_tent/copy_on_install/public/javascripts
136
+ create /Users/greg/temp/test_s_tent/copy_on_install/public/stylesheets
137
+ create /Users/greg/temp/test_s_tent/tasks
138
+ create /Users/greg/temp/test_s_tent/README
139
+ create /Users/greg/temp/test_s_tent/INSTALL
140
+ create /Users/greg/temp/test_s_tent/LICENCE
141
+ create /Users/greg/temp/test_s_tent/tasks/test_s_tent.rake
142
+ create /Users/greg/temp/test_s_tent/generators
143
+ create /Users/greg/temp/test_s_tent/generators/test_s_tent.rb
144
+ create /Users/greg/temp/test_s_tent/generators/template
145
+ create /Users/greg/temp/test_s_tent/generators/template/hello_view.rb
146
+ create /Users/greg/temp/test_s_tent/generators/template/world_controller.rb
147
+ create /Users/greg/temp/test_s_tent/lib
148
+ create /Users/greg/temp/test_s_tent/lib/test_s_tent
149
+ create /Users/greg/temp/test_s_tent/init.rb
150
+ create /Users/greg/temp/test_s_tent/lib/test_s_tent/view_helpers.rb
151
+ create /Users/greg/temp/test_s_tent/lib/test_s_tent/controller_helpers.rb
152
+ </pre>
153
+
154
+
155
+
156
+
157
+
158
+
159
+
160
+ </div>
161
+ </div>
162
+
163
+
164
+ </div>
165
+ </body>
166
+ </html>
@@ -0,0 +1,10 @@
1
+
2
+ <HTML>
3
+ <HEAD>
4
+ <META HTTP-EQUIV="refresh" content="0;URL=files/README.html">
5
+ <TITLE>Backpack, the Documentation</TITLE>
6
+ </HEAD>
7
+ <BODY>
8
+ Click <a href="files/README.html">here</a> to open the docs.
9
+ </BODY>
10
+ </HTML>
Binary file
@@ -0,0 +1,106 @@
1
+
2
+ body {
3
+ font: normal 14px verdana,arial,'Bitstream Vera Sans',helvetica,sans-serif;
4
+ line-height: 160%;
5
+ padding: 0; margin: 0;
6
+ margin-bottom: 30px;
7
+ /* background-color: #402; */
8
+ background-color: #CCCC99;
9
+ }
10
+ h1, h2, h3, h4 {
11
+ font-family: Utopia, Georgia, serif;
12
+ font-weight: bold;
13
+ letter-spacing: -0.018em;
14
+ }
15
+ h1 { font-size: 24px; margin: .15em 1em 0 0 }
16
+ h2 { font-size: 24px }
17
+ h3 { font-size: 19px }
18
+ h4 { font-size: 17px; font-weight: normal; }
19
+ h4.ruled { border-bottom: solid 1px #CC9; }
20
+ h2.ruled { padding-top: 35px; border-top: solid 1px #AA5; }
21
+
22
+ /* Link styles */
23
+ :link, :visited {
24
+
25
+ }
26
+ :link:hover, :visited:hover {
27
+
28
+ }
29
+ #fullpage {
30
+ width: 720px;
31
+ padding-top: 20px;
32
+ margin: 0 auto;
33
+ }
34
+ .page_shade, .page {
35
+ border-left: 1px solid black;
36
+ border-right: 1px solid black;
37
+ border-bottom: 1px solid black;
38
+ background-color: #FFFFFF;
39
+ }
40
+ .page {
41
+ padding: 20px 35px;
42
+ }
43
+ .page .header {
44
+ float: right;
45
+ color: #777;
46
+ font-size: 10px;
47
+ }
48
+ .page h1, .page h2, .page h3 {
49
+ clear: both;
50
+ text-align: center;
51
+ }
52
+ #pager {
53
+ background-color: #EEEEAE;
54
+ border-top: 2px solid black;
55
+ border-left: 2px solid black;
56
+ border-right: 2px solid black;
57
+ border-bottom: 1px dashed #999966;
58
+ padding: 20px 0 20px 20px;
59
+ color: #666633;
60
+ font-size: 11px;
61
+ }
62
+ #pager :link, #pager :visited {
63
+ color: #8E2400;
64
+ padding: 0px 5px;
65
+ }
66
+ #pager :link:hover, #pager :visited:hover {
67
+ color: #8E2400;
68
+ }
69
+ #pagertd {
70
+ font-size: 11px;
71
+ }
72
+ #logo { float: left; }
73
+ #menu {
74
+ padding: 4px 12px;
75
+ margin: 0;
76
+ }
77
+ #menu h3 { padding: 0; margin: 0; }
78
+ #menu #links { float: right; }
79
+ pre { font-weight: bold; color: black; }
80
+ tt { color: #703; font-size: 12pt; }
81
+ .dyn-source {
82
+ background-color: #EEEEEE;
83
+ border: 1px solid #CCCCCC;
84
+ padding: 4px 8px;
85
+ margin: 0;
86
+ display: none; }
87
+ .dyn-source pre {
88
+ color: #000000;
89
+ font-size: 8pt;
90
+ font-familly: monospace;
91
+
92
+ }
93
+ .source-link { text-align: right; font-size: 8pt; }
94
+ .ruby-comment { color: black; font-style: italic }
95
+ .ruby-constant { color: #123456; font-weight: bold; }
96
+ .ruby-identifier { color: #005599; }
97
+ .ruby-ivar { color: orange; }
98
+ .ruby-keyword { color: red; font-weight: bold }
99
+ .ruby-node { color: #FFFFFF; }
100
+ .ruby-operator { color: #055005; }
101
+ .ruby-regexp { color: #DDFFDD; }
102
+ .ruby-value { color: #FFAAAA; font-style: italic }
103
+ .kw { color: red; font-weight: bold }
104
+ .cmt { color: green; font-style: italic }
105
+ .str { color: #EECCCC; font-style: italic }
106
+ .re { color: #EECCCC; }
Binary file
@@ -23,7 +23,7 @@
23
23
  @<%= @generator_name %>_class = output_file.classify
24
24
  @<%= @generator_name %>_file = @<%= @generator_name %>_class.underscore
25
25
 
26
- destination_file = File.dirname( $0 ) + "/../app/<%= @generator_type %>/" + @<%= @generator_name %>_file + ".rb"
26
+ destination_file = File.dirname( $0 ) + "/../app/<%= @generator_type.pluralize %>/" + @<%= @generator_name %>_file + ".rb"
27
27
  createFile( destination_file ) do |io|
28
28
  io.puts plugin_template( File.join( File.expand_path( File.dirname(__FILE__) ), "template/<%= @generator_name %>_<%= @generator_type %>.rb" ), binding )
29
29
  end
@@ -1,17 +1,17 @@
1
1
  #
2
- # Project <%%= @app.environment.appname %%>
2
+ # Project <%%= @app.environment.appname %>
3
3
  #
4
- # Created using bivouac on <%%= Time.now %%>.
5
- # Copyright (c) <%%= Time.now.year %%> __My__. All rights reserved.
4
+ # Created using bivouac on <%%= Time.now %>.
5
+ # Copyright (c) <%%= Time.now.year %> __My__. All rights reserved.
6
6
  #
7
7
 
8
- module <%%= @app.environment.appname %%>::<%= @generator_type_class %>
9
- class <%%= @<%= @generator_name %>_class %%> < R '/<%%= @<%= @generator_name %>_file %%>'
8
+ module <%%= @app.environment.appname %>::<%= @generator_type_class %>
9
+ class <%%= @<%= @generator_name %>_class %> < R '/<%%= @<%= @generator_name %>_file %>'
10
10
  def get
11
- render :<%%= @<%= @generator_name %>_file %%>
11
+ render :<%%= @<%= @generator_name %>_file %>
12
12
  end
13
13
  def post
14
- render :<%%= @<%= @generator_name %>_file %%>
14
+ render :<%%= @<%= @generator_name %>_file %>
15
15
  end
16
16
  end
17
17
  end
@@ -1,12 +1,12 @@
1
1
  #
2
- # Project <%%= @app.environment.appname %%>
2
+ # Project <%%= @app.environment.appname %>
3
3
  #
4
- # Created using bivouac on <%%= Time.now %%>.
5
- # Copyright (c) <%%= Time.now.year %%> __My__. All rights reserved.
4
+ # Created using bivouac on <%%= Time.now %>.
5
+ # Copyright (c) <%%= Time.now.year %> __My__. All rights reserved.
6
6
  #
7
7
 
8
- module <%%= @app.environment.appname %%>::<%= @generator_type_class %>
9
- def <%%= @<%= @generator_name %>_file %%>
8
+ module <%%= @app.environment.appname %>::<%= @generator_type_class %>
9
+ def <%%= @<%= @generator_name %>_file %>
10
10
  # ...
11
11
  end
12
12
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: backpack
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - "Gr\xC3\xA9goire Lejeune"
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2008-04-10 00:00:00 +02:00
12
+ date: 2008-04-11 00:00:00 +02:00
13
13
  default_executable:
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
@@ -37,6 +37,17 @@ files:
37
37
  - AUTHORS
38
38
  - setup.rb
39
39
  - bin/backpack
40
+ - doc/rdoc
41
+ - doc/rdoc/classes
42
+ - doc/rdoc/created.rid
43
+ - doc/rdoc/files
44
+ - doc/rdoc/files/AUTHORS.html
45
+ - doc/rdoc/files/COPYING.html
46
+ - doc/rdoc/files/README.html
47
+ - doc/rdoc/index.html
48
+ - doc/rdoc/permalink.gif
49
+ - doc/rdoc/rdoc-style.css
50
+ - doc/rdoc/rubyfr.png
40
51
  - lib/backpack.rb
41
52
  - lib/template
42
53
  - lib/template/generators