drydock 0.3.2 → 0.3.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,7 +1,7 @@
1
1
  <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2
2
  <html lang='en'>
3
3
  <head>
4
- <title>File: drydock.rb [Drydock, A seaworthy DSL for command-line apps.]</title>
4
+ <title>File: drydock.rb [A seaworthy DSL for writing command line apps]</title>
5
5
  <meta content='text/html; charset=utf-8' http-equiv='Content-Type'>
6
6
  <link href='../.././rdoc-style.css' media='screen' rel='stylesheet' type='text/css'>
7
7
  <script type='text/javascript'>
@@ -31,7 +31,7 @@
31
31
  </div>
32
32
  <div class='last-update'>
33
33
  Last Update:
34
- <span class='datetime'>Fri Feb 06 10:27:45 -0500 2009</span>
34
+ <span class='datetime'>Sat Feb 14 14:08:44 -0500 2009</span>
35
35
  </div>
36
36
  </div>
37
37
  <div id='content'>
@@ -1,7 +1,7 @@
1
1
  <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2
2
  <html lang='en'>
3
3
  <head>
4
- <title>Classes [Drydock, A seaworthy DSL for command-line apps.]</title>
4
+ <title>Classes [A seaworthy DSL for writing command line apps]</title>
5
5
  <meta content='text/html; charset=utf-8' http-equiv='Content-Type'>
6
6
  <link href='rdoc-style.css' media='screen' rel='stylesheet' type='text/css'>
7
7
  <base target='docwin'>
@@ -1,7 +1,7 @@
1
1
  <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2
2
  <html lang='en'>
3
3
  <head>
4
- <title>Files [Drydock, A seaworthy DSL for command-line apps.]</title>
4
+ <title>Files [A seaworthy DSL for writing command line apps]</title>
5
5
  <meta content='text/html; charset=utf-8' http-equiv='Content-Type'>
6
6
  <link href='rdoc-style.css' media='screen' rel='stylesheet' type='text/css'>
7
7
  <base target='docwin'>
@@ -1,7 +1,7 @@
1
1
  <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2
2
  <html lang='en'>
3
3
  <head>
4
- <title>Methods [Drydock, A seaworthy DSL for command-line apps.]</title>
4
+ <title>Methods [A seaworthy DSL for writing command line apps]</title>
5
5
  <meta content='text/html; charset=utf-8' http-equiv='Content-Type'>
6
6
  <link href='rdoc-style.css' media='screen' rel='stylesheet' type='text/css'>
7
7
  <base target='docwin'>
@@ -4331,36 +4331,35 @@
4331
4331
 
4332
4332
  Element.addMethods();
4333
4333
  var search_index = [
4334
- { method: 'after', module: 'drydock', html: '<a href="classes/Drydock.html#M000007"><span class="method_name">after</span> <span class="module_name">(Drydock)</span></a>' },
4335
- { method: 'alias_command', module: 'drydock', html: '<a href="classes/Drydock.html#M000015"><span class="method_name">alias_command</span> <span class="module_name">(Drydock)</span></a>' },
4336
- { method: 'before', module: 'drydock', html: '<a href="classes/Drydock.html#M000006"><span class="method_name">before</span> <span class="module_name">(Drydock)</span></a>' },
4337
- { method: 'call', module: 'drydock::command', html: '<a href="classes/Drydock/Command.html#M000028"><span class="method_name">call</span> <span class="module_name">(Drydock::Command)</span></a>' },
4338
- { method: 'command', module: 'drydock', html: '<a href="classes/Drydock.html#M000014"><span class="method_name">command</span> <span class="module_name">(Drydock)</span></a>' },
4339
- { method: 'command_alias', module: 'drydock', html: '<a href="classes/Drydock.html#M000016"><span class="method_name">command_alias</span> <span class="module_name">(Drydock)</span></a>' },
4340
- { method: 'commands', module: 'drydock', html: '<a href="classes/Drydock.html#M000017"><span class="method_name">commands</span> <span class="module_name">(Drydock)</span></a>' },
4341
- { method: 'debug', module: 'drydock', html: '<a href="classes/Drydock.html#M000002"><span class="method_name">debug</span> <span class="module_name">(Drydock)</span></a>' },
4342
- { method: 'debug?', module: 'drydock', html: '<a href="classes/Drydock.html#M000003"><span class="method_name">debug?</span> <span class="module_name">(Drydock)</span></a>' },
4343
- { method: 'default', module: 'drydock', html: '<a href="classes/Drydock.html#M000004"><span class="method_name">default</span> <span class="module_name">(Drydock)</span></a>' },
4344
- { method: 'get_current_option_parser', module: 'drydock', html: '<a href="classes/Drydock.html#M000010"><span class="method_name">get_current_option_parser</span> <span class="module_name">(Drydock)</span></a>' },
4345
- { method: 'global_option', module: 'drydock', html: '<a href="classes/Drydock.html#M000012"><span class="method_name">global_option</span> <span class="module_name">(Drydock)</span></a>' },
4346
- { method: 'global_usage', module: 'drydock', html: '<a href="classes/Drydock.html#M000008"><span class="method_name">global_usage</span> <span class="module_name">(Drydock)</span></a>' },
4347
- { method: 'has_run?', module: 'drydock', html: '<a href="classes/Drydock.html#M000020"><span class="method_name">has_run?</span> <span class="module_name">(Drydock)</span></a>' },
4348
- { method: 'ignore', module: 'drydock', html: '<a href="classes/Drydock.html#M000011"><span class="method_name">ignore</span> <span class="module_name">(Drydock)</span></a>' },
4349
- { method: 'message', module: 'drydock::nocommandsdefined', html: '<a href="classes/Drydock/NoCommandsDefined.html#M000026"><span class="method_name">message</span> <span class="module_name">(Drydock::NoCommandsDefined)</span></a>' },
4350
- { method: 'message', module: 'drydock::invalidargument', html: '<a href="classes/Drydock/InvalidArgument.html#M000025"><span class="method_name">message</span> <span class="module_name">(Drydock::InvalidArgument)</span></a>' },
4351
- { method: 'message', module: 'drydock::unknowncommand', html: '<a href="classes/Drydock/UnknownCommand.html#M000023"><span class="method_name">message</span> <span class="module_name">(Drydock::UnknownCommand)</span></a>' },
4352
- { method: 'message', module: 'drydock::missingargument', html: '<a href="classes/Drydock/MissingArgument.html#M000030"><span class="method_name">message</span> <span class="module_name">(Drydock::MissingArgument)</span></a>' },
4353
- { method: 'new', module: 'drydock::invalidargument', html: '<a href="classes/Drydock/InvalidArgument.html#M000024"><span class="method_name">new</span> <span class="module_name">(Drydock::InvalidArgument)</span></a>' },
4354
- { method: 'new', module: 'drydock::command', html: '<a href="classes/Drydock/Command.html#M000027"><span class="method_name">new</span> <span class="module_name">(Drydock::Command)</span></a>' },
4355
- { method: 'new', module: 'drydock::unknowncommand', html: '<a href="classes/Drydock/UnknownCommand.html#M000022"><span class="method_name">new</span> <span class="module_name">(Drydock::UnknownCommand)</span></a>' },
4356
- { method: 'option', module: 'drydock', html: '<a href="classes/Drydock.html#M000013"><span class="method_name">option</span> <span class="module_name">(Drydock)</span></a>' },
4357
- { method: 'response_code', module: 'bin/example', html: '<a href="files/bin/example.html#M000001"><span class="method_name">response_code</span> <span class="module_name">(bin/example)</span></a>' },
4358
- { method: 'run!', module: 'drydock', html: '<a href="classes/Drydock.html#M000021"><span class="method_name">run!</span> <span class="module_name">(Drydock)</span></a>' },
4359
- { method: 'run=', module: 'drydock', html: '<a href="classes/Drydock.html#M000019"><span class="method_name">run=</span> <span class="module_name">(Drydock)</span></a>' },
4360
- { method: 'run?', module: 'drydock', html: '<a href="classes/Drydock.html#M000018"><span class="method_name">run?</span> <span class="module_name">(Drydock)</span></a>' },
4361
- { method: 'stdin', module: 'drydock', html: '<a href="classes/Drydock.html#M000005"><span class="method_name">stdin</span> <span class="module_name">(Drydock)</span></a>' },
4362
- { method: 'to_s', module: 'drydock::command', html: '<a href="classes/Drydock/Command.html#M000029"><span class="method_name">to_s</span> <span class="module_name">(Drydock::Command)</span></a>' },
4363
- { method: 'usage', module: 'drydock', html: '<a href="classes/Drydock.html#M000009"><span class="method_name">usage</span> <span class="module_name">(Drydock)</span></a>' },
4334
+ { method: 'after', module: 'drydock', html: '<a href="classes/Drydock.html#M000006"><span class="method_name">after</span> <span class="module_name">(Drydock)</span></a>' },
4335
+ { method: 'alias_command', module: 'drydock', html: '<a href="classes/Drydock.html#M000014"><span class="method_name">alias_command</span> <span class="module_name">(Drydock)</span></a>' },
4336
+ { method: 'before', module: 'drydock', html: '<a href="classes/Drydock.html#M000005"><span class="method_name">before</span> <span class="module_name">(Drydock)</span></a>' },
4337
+ { method: 'call', module: 'drydock::command', html: '<a href="classes/Drydock/Command.html#M000027"><span class="method_name">call</span> <span class="module_name">(Drydock::Command)</span></a>' },
4338
+ { method: 'command', module: 'drydock', html: '<a href="classes/Drydock.html#M000013"><span class="method_name">command</span> <span class="module_name">(Drydock)</span></a>' },
4339
+ { method: 'command_alias', module: 'drydock', html: '<a href="classes/Drydock.html#M000015"><span class="method_name">command_alias</span> <span class="module_name">(Drydock)</span></a>' },
4340
+ { method: 'commands', module: 'drydock', html: '<a href="classes/Drydock.html#M000016"><span class="method_name">commands</span> <span class="module_name">(Drydock)</span></a>' },
4341
+ { method: 'debug', module: 'drydock', html: '<a href="classes/Drydock.html#M000001"><span class="method_name">debug</span> <span class="module_name">(Drydock)</span></a>' },
4342
+ { method: 'debug?', module: 'drydock', html: '<a href="classes/Drydock.html#M000002"><span class="method_name">debug?</span> <span class="module_name">(Drydock)</span></a>' },
4343
+ { method: 'default', module: 'drydock', html: '<a href="classes/Drydock.html#M000003"><span class="method_name">default</span> <span class="module_name">(Drydock)</span></a>' },
4344
+ { method: 'get_current_option_parser', module: 'drydock', html: '<a href="classes/Drydock.html#M000009"><span class="method_name">get_current_option_parser</span> <span class="module_name">(Drydock)</span></a>' },
4345
+ { method: 'global_option', module: 'drydock', html: '<a href="classes/Drydock.html#M000011"><span class="method_name">global_option</span> <span class="module_name">(Drydock)</span></a>' },
4346
+ { method: 'global_usage', module: 'drydock', html: '<a href="classes/Drydock.html#M000007"><span class="method_name">global_usage</span> <span class="module_name">(Drydock)</span></a>' },
4347
+ { method: 'has_run?', module: 'drydock', html: '<a href="classes/Drydock.html#M000019"><span class="method_name">has_run?</span> <span class="module_name">(Drydock)</span></a>' },
4348
+ { method: 'ignore', module: 'drydock', html: '<a href="classes/Drydock.html#M000010"><span class="method_name">ignore</span> <span class="module_name">(Drydock)</span></a>' },
4349
+ { method: 'message', module: 'drydock::nocommandsdefined', html: '<a href="classes/Drydock/NoCommandsDefined.html#M000025"><span class="method_name">message</span> <span class="module_name">(Drydock::NoCommandsDefined)</span></a>' },
4350
+ { method: 'message', module: 'drydock::missingargument', html: '<a href="classes/Drydock/MissingArgument.html#M000029"><span class="method_name">message</span> <span class="module_name">(Drydock::MissingArgument)</span></a>' },
4351
+ { method: 'message', module: 'drydock::invalidargument', html: '<a href="classes/Drydock/InvalidArgument.html#M000024"><span class="method_name">message</span> <span class="module_name">(Drydock::InvalidArgument)</span></a>' },
4352
+ { method: 'message', module: 'drydock::unknowncommand', html: '<a href="classes/Drydock/UnknownCommand.html#M000022"><span class="method_name">message</span> <span class="module_name">(Drydock::UnknownCommand)</span></a>' },
4353
+ { method: 'new', module: 'drydock::command', html: '<a href="classes/Drydock/Command.html#M000026"><span class="method_name">new</span> <span class="module_name">(Drydock::Command)</span></a>' },
4354
+ { method: 'new', module: 'drydock::unknowncommand', html: '<a href="classes/Drydock/UnknownCommand.html#M000021"><span class="method_name">new</span> <span class="module_name">(Drydock::UnknownCommand)</span></a>' },
4355
+ { method: 'new', module: 'drydock::invalidargument', html: '<a href="classes/Drydock/InvalidArgument.html#M000023"><span class="method_name">new</span> <span class="module_name">(Drydock::InvalidArgument)</span></a>' },
4356
+ { method: 'option', module: 'drydock', html: '<a href="classes/Drydock.html#M000012"><span class="method_name">option</span> <span class="module_name">(Drydock)</span></a>' },
4357
+ { method: 'run!', module: 'drydock', html: '<a href="classes/Drydock.html#M000020"><span class="method_name">run!</span> <span class="module_name">(Drydock)</span></a>' },
4358
+ { method: 'run=', module: 'drydock', html: '<a href="classes/Drydock.html#M000018"><span class="method_name">run=</span> <span class="module_name">(Drydock)</span></a>' },
4359
+ { method: 'run?', module: 'drydock', html: '<a href="classes/Drydock.html#M000017"><span class="method_name">run?</span> <span class="module_name">(Drydock)</span></a>' },
4360
+ { method: 'stdin', module: 'drydock', html: '<a href="classes/Drydock.html#M000004"><span class="method_name">stdin</span> <span class="module_name">(Drydock)</span></a>' },
4361
+ { method: 'to_s', module: 'drydock::command', html: '<a href="classes/Drydock/Command.html#M000028"><span class="method_name">to_s</span> <span class="module_name">(Drydock::Command)</span></a>' },
4362
+ { method: 'usage', module: 'drydock', html: '<a href="classes/Drydock.html#M000008"><span class="method_name">usage</span> <span class="module_name">(Drydock)</span></a>' },
4364
4363
  ]
4365
4364
  $(document).observe('dom:loaded', function() {
4366
4365
  // Setup search-during-typing.
@@ -4423,36 +4422,35 @@
4423
4422
  </form>
4424
4423
  <ol class='methods' id='search-results' style='display: none'></ol>
4425
4424
  <ol class='methods' id='index-entries'>
4426
- <li><a href="classes/Drydock.html#M000007"><span class="method_name">after</span> <span class="module_name">(Drydock)</span></a></li>
4427
- <li><a href="classes/Drydock.html#M000015"><span class="method_name">alias_command</span> <span class="module_name">(Drydock)</span></a></li>
4428
- <li><a href="classes/Drydock.html#M000006"><span class="method_name">before</span> <span class="module_name">(Drydock)</span></a></li>
4429
- <li><a href="classes/Drydock/Command.html#M000028"><span class="method_name">call</span> <span class="module_name">(Drydock::Command)</span></a></li>
4430
- <li><a href="classes/Drydock.html#M000014"><span class="method_name">command</span> <span class="module_name">(Drydock)</span></a></li>
4431
- <li><a href="classes/Drydock.html#M000016"><span class="method_name">command_alias</span> <span class="module_name">(Drydock)</span></a></li>
4432
- <li><a href="classes/Drydock.html#M000017"><span class="method_name">commands</span> <span class="module_name">(Drydock)</span></a></li>
4433
- <li><a href="classes/Drydock.html#M000002"><span class="method_name">debug</span> <span class="module_name">(Drydock)</span></a></li>
4434
- <li><a href="classes/Drydock.html#M000003"><span class="method_name">debug?</span> <span class="module_name">(Drydock)</span></a></li>
4435
- <li><a href="classes/Drydock.html#M000004"><span class="method_name">default</span> <span class="module_name">(Drydock)</span></a></li>
4436
- <li><a href="classes/Drydock.html#M000010"><span class="method_name">get_current_option_parser</span> <span class="module_name">(Drydock)</span></a></li>
4437
- <li><a href="classes/Drydock.html#M000012"><span class="method_name">global_option</span> <span class="module_name">(Drydock)</span></a></li>
4438
- <li><a href="classes/Drydock.html#M000008"><span class="method_name">global_usage</span> <span class="module_name">(Drydock)</span></a></li>
4439
- <li><a href="classes/Drydock.html#M000020"><span class="method_name">has_run?</span> <span class="module_name">(Drydock)</span></a></li>
4440
- <li><a href="classes/Drydock.html#M000011"><span class="method_name">ignore</span> <span class="module_name">(Drydock)</span></a></li>
4441
- <li><a href="classes/Drydock/NoCommandsDefined.html#M000026"><span class="method_name">message</span> <span class="module_name">(Drydock::NoCommandsDefined)</span></a></li>
4442
- <li><a href="classes/Drydock/InvalidArgument.html#M000025"><span class="method_name">message</span> <span class="module_name">(Drydock::InvalidArgument)</span></a></li>
4443
- <li><a href="classes/Drydock/UnknownCommand.html#M000023"><span class="method_name">message</span> <span class="module_name">(Drydock::UnknownCommand)</span></a></li>
4444
- <li><a href="classes/Drydock/MissingArgument.html#M000030"><span class="method_name">message</span> <span class="module_name">(Drydock::MissingArgument)</span></a></li>
4445
- <li><a href="classes/Drydock/InvalidArgument.html#M000024"><span class="method_name">new</span> <span class="module_name">(Drydock::InvalidArgument)</span></a></li>
4446
- <li><a href="classes/Drydock/Command.html#M000027"><span class="method_name">new</span> <span class="module_name">(Drydock::Command)</span></a></li>
4447
- <li><a href="classes/Drydock/UnknownCommand.html#M000022"><span class="method_name">new</span> <span class="module_name">(Drydock::UnknownCommand)</span></a></li>
4448
- <li><a href="classes/Drydock.html#M000013"><span class="method_name">option</span> <span class="module_name">(Drydock)</span></a></li>
4449
- <li><a href="files/bin/example.html#M000001"><span class="method_name">response_code</span> <span class="module_name">(bin/example)</span></a></li>
4450
- <li><a href="classes/Drydock.html#M000021"><span class="method_name">run!</span> <span class="module_name">(Drydock)</span></a></li>
4451
- <li><a href="classes/Drydock.html#M000019"><span class="method_name">run=</span> <span class="module_name">(Drydock)</span></a></li>
4452
- <li><a href="classes/Drydock.html#M000018"><span class="method_name">run?</span> <span class="module_name">(Drydock)</span></a></li>
4453
- <li><a href="classes/Drydock.html#M000005"><span class="method_name">stdin</span> <span class="module_name">(Drydock)</span></a></li>
4454
- <li><a href="classes/Drydock/Command.html#M000029"><span class="method_name">to_s</span> <span class="module_name">(Drydock::Command)</span></a></li>
4455
- <li><a href="classes/Drydock.html#M000009"><span class="method_name">usage</span> <span class="module_name">(Drydock)</span></a></li>
4425
+ <li><a href="classes/Drydock.html#M000006"><span class="method_name">after</span> <span class="module_name">(Drydock)</span></a></li>
4426
+ <li><a href="classes/Drydock.html#M000014"><span class="method_name">alias_command</span> <span class="module_name">(Drydock)</span></a></li>
4427
+ <li><a href="classes/Drydock.html#M000005"><span class="method_name">before</span> <span class="module_name">(Drydock)</span></a></li>
4428
+ <li><a href="classes/Drydock/Command.html#M000027"><span class="method_name">call</span> <span class="module_name">(Drydock::Command)</span></a></li>
4429
+ <li><a href="classes/Drydock.html#M000013"><span class="method_name">command</span> <span class="module_name">(Drydock)</span></a></li>
4430
+ <li><a href="classes/Drydock.html#M000015"><span class="method_name">command_alias</span> <span class="module_name">(Drydock)</span></a></li>
4431
+ <li><a href="classes/Drydock.html#M000016"><span class="method_name">commands</span> <span class="module_name">(Drydock)</span></a></li>
4432
+ <li><a href="classes/Drydock.html#M000001"><span class="method_name">debug</span> <span class="module_name">(Drydock)</span></a></li>
4433
+ <li><a href="classes/Drydock.html#M000002"><span class="method_name">debug?</span> <span class="module_name">(Drydock)</span></a></li>
4434
+ <li><a href="classes/Drydock.html#M000003"><span class="method_name">default</span> <span class="module_name">(Drydock)</span></a></li>
4435
+ <li><a href="classes/Drydock.html#M000009"><span class="method_name">get_current_option_parser</span> <span class="module_name">(Drydock)</span></a></li>
4436
+ <li><a href="classes/Drydock.html#M000011"><span class="method_name">global_option</span> <span class="module_name">(Drydock)</span></a></li>
4437
+ <li><a href="classes/Drydock.html#M000007"><span class="method_name">global_usage</span> <span class="module_name">(Drydock)</span></a></li>
4438
+ <li><a href="classes/Drydock.html#M000019"><span class="method_name">has_run?</span> <span class="module_name">(Drydock)</span></a></li>
4439
+ <li><a href="classes/Drydock.html#M000010"><span class="method_name">ignore</span> <span class="module_name">(Drydock)</span></a></li>
4440
+ <li><a href="classes/Drydock/NoCommandsDefined.html#M000025"><span class="method_name">message</span> <span class="module_name">(Drydock::NoCommandsDefined)</span></a></li>
4441
+ <li><a href="classes/Drydock/MissingArgument.html#M000029"><span class="method_name">message</span> <span class="module_name">(Drydock::MissingArgument)</span></a></li>
4442
+ <li><a href="classes/Drydock/InvalidArgument.html#M000024"><span class="method_name">message</span> <span class="module_name">(Drydock::InvalidArgument)</span></a></li>
4443
+ <li><a href="classes/Drydock/UnknownCommand.html#M000022"><span class="method_name">message</span> <span class="module_name">(Drydock::UnknownCommand)</span></a></li>
4444
+ <li><a href="classes/Drydock/Command.html#M000026"><span class="method_name">new</span> <span class="module_name">(Drydock::Command)</span></a></li>
4445
+ <li><a href="classes/Drydock/UnknownCommand.html#M000021"><span class="method_name">new</span> <span class="module_name">(Drydock::UnknownCommand)</span></a></li>
4446
+ <li><a href="classes/Drydock/InvalidArgument.html#M000023"><span class="method_name">new</span> <span class="module_name">(Drydock::InvalidArgument)</span></a></li>
4447
+ <li><a href="classes/Drydock.html#M000012"><span class="method_name">option</span> <span class="module_name">(Drydock)</span></a></li>
4448
+ <li><a href="classes/Drydock.html#M000020"><span class="method_name">run!</span> <span class="module_name">(Drydock)</span></a></li>
4449
+ <li><a href="classes/Drydock.html#M000018"><span class="method_name">run=</span> <span class="module_name">(Drydock)</span></a></li>
4450
+ <li><a href="classes/Drydock.html#M000017"><span class="method_name">run?</span> <span class="module_name">(Drydock)</span></a></li>
4451
+ <li><a href="classes/Drydock.html#M000004"><span class="method_name">stdin</span> <span class="module_name">(Drydock)</span></a></li>
4452
+ <li><a href="classes/Drydock/Command.html#M000028"><span class="method_name">to_s</span> <span class="module_name">(Drydock::Command)</span></a></li>
4453
+ <li><a href="classes/Drydock.html#M000008"><span class="method_name">usage</span> <span class="module_name">(Drydock)</span></a></li>
4456
4454
  </ol>
4457
4455
  </div>
4458
4456
  </body>
@@ -1,7 +1,7 @@
1
1
  <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">
2
2
  <html lang='en' xml:lang='en' xmlns='http://www.w3.org/1999/xhtml'>
3
3
  <head>
4
- <title>Drydock, A seaworthy DSL for command-line apps.</title>
4
+ <title>A seaworthy DSL for writing command line apps</title>
5
5
  <meta content='text/html; charset=utf-8' http-equiv='Content-Type'>
6
6
  </head>
7
7
  <frameset border='1' bordercolor='gray' cols='20%, *' frameborder='1'>
@@ -1,6 +1,6 @@
1
1
  @spec = Gem::Specification.new do |s|
2
2
  s.name = %q{drydock}
3
- s.version = "0.3.2"
3
+ s.version = "0.3.3"
4
4
  s.specification_version = 1 if s.respond_to? :specification_version=
5
5
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
6
6
 
@@ -24,6 +24,12 @@ module Drydock
24
24
  #
25
25
  class Command
26
26
  attr_reader :cmd, :alias
27
+
28
+ # The default constructor sets the short name of the command
29
+ # and stores a reference to the block (if supplied).
30
+ # You don't need to override this method to add functionality
31
+ # to your custom Command classes. Define an +init+ method instead.
32
+ # It will be called just before the block is executed.
27
33
  # +cmd+ is the short name of this command.
28
34
  # +b+ is the block associated to this command.
29
35
  def initialize(cmd, &b)
@@ -33,6 +39,8 @@ module Drydock
33
39
 
34
40
  # Execute the block.
35
41
  #
42
+ # Calls self.init before calling the block. Implement this method when
43
+ #
36
44
  # +cmd_str+ is the short name used to evoke this command. It will equal @cmd
37
45
  # unless an alias was used used to evoke this command.
38
46
  # +argv+ an array of unnamed arguments. If ignore :options was declared this
@@ -45,6 +53,9 @@ module Drydock
45
53
  global_options.merge(options).each_pair do |n,v|
46
54
  self.send("#{n}=", v)
47
55
  end
56
+
57
+ self.init if respond_to? :init
58
+
48
59
  block_args = [self, argv, stdin] # TODO: review order
49
60
  @b.call(*block_args[0..(@b.arity-1)]) # send only as many args as defined
50
61
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: drydock
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.2
4
+ version: 0.3.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Delano Mandelbaum