]> git.donarmstrong.com Git - lilypond.git/commitdiff
*** empty log message ***
authorhanwen <hanwen>
Fri, 3 Mar 2006 11:01:08 +0000 (11:01 +0000)
committerhanwen <hanwen>
Fri, 3 Mar 2006 11:01:08 +0000 (11:01 +0000)
scripts/lilypond-book.py

index ef76bda7bc2a16b918b00e0d6e84491e3e27b5fc..5426c63374313d5533ceaa5595c832edc3749593 100644 (file)
@@ -126,8 +126,8 @@ def warranty ():
 
 %s
 %s
-'''  ( _('Copyright (c) %s by') % '2001--2006',
-       authors,
+''' % ( _('Copyright (c) %s by') % '2001--2006',
+       ' '.join (authors),
        _('Distributed under terms of the GNU General Public License.'),
        _('It comes with NO WARRANTY.')))
 
@@ -161,7 +161,9 @@ def get_option_parser ():
                      help=_ ('''extract all PostScript fonts into INPUT.psfonts for LaTeX'''
                              '''must use this with dvips -h INPUT.psfonts'''),
                      default=None)
-       p.add_option ('-V', '--verbose', help=_("be verbose"), action="store_true",
+       p.add_option ('-V', '--verbose', help=_("be verbose"),
+                     action="store_true",
+                     default=False,
                      dest="verbose")
                      
        p.add_option ('-w', '--warranty',
@@ -1653,24 +1655,29 @@ def do_file (input_filename):
                raise Compile_error
 
 def do_options ():
-       opt_parser = get_option_parser()
-       (options, args) = opt_parser.parse_args ()
 
-       if options.format in ('texi-html', 'texi'):
-               options.format = TEXINFO
-       options.use_hash = True
+       global global_options
 
-       options.include_path =  map (os.path.abspath, options.include_path)
+       opt_parser = get_option_parser()
+       (global_options, args) = opt_parser.parse_args ()
 
-       global global_options
-       global_options = options
+       if global_options.format in ('texi-html', 'texi'):
+               global_options.format = TEXINFO
+       global_options.use_hash = True
+
+       global_options.include_path =  map (os.path.abspath, global_options.include_path)
+       
+       if global_options.warranty:
+               warranty ()
+               exit (0)
+       if not args or len (args) > 1:
+               opt_parser.print_help ()
+               exit (2)
+               
        return args
 
 def main ():
        files = do_options ()
-       if not files or len (files) > 1:
-               ly.help ()
-               exit (2)
 
        file = files[0]