]> diplodocus.org Git - flac-archive/blobdiff - fa-flacd
(flac): UNTESTED: Put disc number at the front of the output file name,
[flac-archive] / fa-flacd
index 2873a41..59e9c26 100755 (executable)
--- a/fa-flacd
+++ b/fa-flacd
@@ -142,7 +142,7 @@ def flac(dir, artist, album, discnum, tracknum, track_tags, disc_artist, tags):
     if tracknum == None:
         outfile = album
         if discnum != None:
-            outfile = ''.join([outfile, ' (disc ', discnum, ')'])
+            outfile = ''.join([discnum, ' ', outfile])
         run_flac('wav', 'cue', '/'.join(['..', artist, outfile]), tags)
         files = ['%s/%s.flac' % (artist, outfile)]
 
@@ -255,7 +255,11 @@ def flacloop(maxjobs):
                     else:
                         # multi-file
                         # Don't need cue file.
-                        c(os.unlink, dir[0] + '/cue')
+                        try:
+                            c(os.unlink, dir[0] + '/cue')
+                        except EnvironmentError, error:
+                            if error.errno != ENOENT:
+                                raise error
 
                         # Go over @tags, store all [n] tags in a list keyed by
                         # n in %tracks_to_tags, store all ARTIST (not