bug-lilypond
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: convert-ly from the commandline under windows corrupted?


From: David Kastrup
Subject: Re: convert-ly from the commandline under windows corrupted?
Date: Sat, 17 Aug 2013 23:22:20 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

Eluze <address@hidden> writes:

> dak wrote
>> The corresponding passage in scripts/convert-ly.py reads
>> 
>>     if global_options.edit:
>>         try:
>>             os.remove (infile_name + '~')
>>         except:
>>             pass
>>         os.rename (infile_name, infile_name + '~')
>>         outfile = open (infile_name, 'w')
>>     else:
>>         outfile = sys.stdout
>> 
>>     outfile.write (result)
>>     
>>     sys.stderr.flush ()
>> 
>>     return errors
>> 
>> which is quite unspectacular.  So either there is still a permission
>> problem, or your version of Python and Windows just don't cooperate
>> sensibly on sys.stdout.
>
> after looking up Martin Tarenskeen's indent-ly.py I replaced 
>
>     # sys.stderr.flush () 
>
> by
>
>     outfile.close()
>
> and it works!
>
> does that make sense?!

Not to me.  But that's par for the course for Windows.

-- 
David Kastrup




reply via email to

[Prev in Thread] Current Thread [Next in Thread]