]> git.donarmstrong.com Git - lilypond.git/commitdiff
Applied Yoshinobu Ishizaki's patch.
authorGraham Percival <graham@percival-music.ca>
Wed, 13 Jul 2005 08:07:48 +0000 (08:07 +0000)
committerGraham Percival <graham@percival-music.ca>
Wed, 13 Jul 2005 08:07:48 +0000 (08:07 +0000)
ChangeLog
THANKS
scripts/lilypond-book.py

index 21fb99d8bb0b7438817485f9b478c598ffb1cf78..03677cc680ac0d055d4ac48db22b4cb7d6defcc9 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2005-07-13  Yoshinobu Isizaki  <isizaki@mte.biglobe.ne.jp>
+
+       * scripts/lilypond-book.py: Prevent occuring error when
+       'lilypond-book --output=foo/ somefile.ly' is executed multiple
+       times and target file shoud be overwritten.  (Error message said
+       'input file and output file is same'.)
+
 2005-07-13  Graham Percival  <gperlist@shaw.ca>
 
        * input/regression/slur-extreme.ly, input/regression/slur-scoring.ly,
@@ -7,6 +14,8 @@
 
        * Documentation/user/converters.itely: fix URL for Noteedit and Rosegarden.
 
+       * THANKS: added Yoshinobu Isizaki.
+
 2005-07-12  Han-Wen Nienhuys  <hanwen@xs4all.nl>
 
        * scm/define-markup-commands.scm (justify-field): add. 
diff --git a/THANKS b/THANKS
index 4712da10e69c27e6225721b465a2b695ce47425b..7f59ec951b389a47587965030ae365be64499b76 100644 (file)
--- a/THANKS
+++ b/THANKS
@@ -12,6 +12,7 @@ Graham Percival   - Documentation Editor
 
 CONTRIBUTORS
 Joe Neeman
+Yoshinobu Ishizaki
 
 
 SPONSORS
index 9ca2640b050f52fe155491afd07a0813ead7215d..c21f0e3f53a924616d10d324b75100da136810f3 100644 (file)
@@ -1428,18 +1428,19 @@ def do_file (input_filename):
                output_filename = '-'
                output_file = sys.stdout
        else:
+               # don't complain when output_name is existing
+               output_filename = input_base + format2ext[format]
                if output_name:
                        if not os.path.isdir (output_name):
                                os.mkdir (output_name, 0777)
                        os.chdir (output_name)
-
-               output_filename = input_base + format2ext[format]
-               if os.path.exists (input_filename) \
-                  and os.path.exists (output_filename) \
-                  and os.path.samefile (output_filename, input_fullname):
-                       ly.error (
-                         _ ("Output would overwrite input file; use --output."))
-                       ly.exit (2)
+               else: 
+                       if os.path.exists (input_filename) \
+                          and os.path.exists (output_filename) \
+                          and os.path.samefile (output_filename, input_fullname):
+                          ly.error (
+                          _ ("Output would overwrite input file; use --output."))
+                          ly.exit (2)
 
        try:
                ly.progress (_ ("Reading %s...") % input_fullname)