~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/commands.py

  • Committer: Aaron Bentley
  • Date: 2006-07-12 19:21:38 UTC
  • mto: This revision was merged to the branch mainline in revision 1934.
  • Revision ID: abentley@panoramicfeedback.com-20060712192138-981a109321bd4a5b
Use optparse for generating option help

Show diffs side-by-side

added added

removed removed

Lines of Context:
367
367
            option_strings.append('-%s' % short_name)
368
368
        optargfn = option.type
369
369
        if optargfn is None:
370
 
            parser.add_option(action='store_true', dest=name, 
 
370
            parser.add_option(action='store_true', dest=name, help=option.help,
371
371
                              default=OptionParser.DEFAULT_VALUE, 
372
372
                              *option_strings)
373
373
        else:
374
374
            parser.add_option(action='callback', callback=type_callback, 
375
 
                              type='string',
 
375
                              type='string', help=option.help,
376
376
                              default=OptionParser.DEFAULT_VALUE, 
377
377
                              callback_args=(name, optargfn), *option_strings)
378
378
    return parser