NORAGGED_RIGHT = 'noragged-right'
NOTES = 'body'
NOTIME = 'notime'
-NOSTAFF = 'nostaff'
OUTPUT = 'output'
OUTPUTIMAGE = 'outputimage'
PAPER = 'paper'
-# NOTIME, NOSTAFF and NOGETTEXT have no opposite so they aren't part of
-# this dictionary.
+# NOTIME and NOGETTEXT have no opposite so they aren't part of this
+# dictionary.
no_options = {
NOFRAGMENT: FRAGMENT,
NOINDENT: INDENT,
\context {
\Staff
\remove "Time_signature_engraver"
- }''',
- NOSTAFF: r'''
- \context {
- \Score
- timing = ##f
- }
- \context {
- \Staff
- \remove "Time_signature_engraver"
- \remove "Clef_engraver"
- \remove "Staff_symbol_engraver"
}''',
},
if not os.path.isdir (dst_path):
os.makedirs (dst_path)
try:
- os.link (src, dst)
- except AttributeError:
- shutil.copyfile (src, dst)
- except OSError:
+ if (self.global_options.use_source_file_names
+ and isinstance (self, LilypondFileSnippet)):
+ fout = open (dst, 'w')
+ fin = open (src, 'r')
+ for line in fin.readlines ():
+ fout.write (line.replace (self.basename (), self.final_basename ()))
+ fout.close ()
+ fin.close ()
+ else:
+ try:
+ os.link (src, dst)
+ except AttributeError:
+ shutil.copyfile (src, dst)
+ except (IOError, OSError):
error (_ ('Could not overwrite file %s') % dst)
raise CompileError(self.basename())