- Timestamp:
- 07/18/16 15:29:42 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/flactrack
r47 r48 16 16 use MusicBrainz; 17 17 use Text::Unidecode; 18 use Cwd; 18 19 19 20 # default to using tags … … 36 37 $TYPE ||= 'mp3'; 37 38 38 # default t he directory to be named like the flac file39 ($DIRECTORY ||= $FLAC_FILE) =~ s/\.flac$//;39 # default to the current directory 40 $DIRECTORY ||= cwd; 40 41 41 42 my $flac = Audio::FLAC::Header->new($FLAC_FILE) or die "Can't read FLAC header from $FLAC_FILE\n"; … … 59 60 } 60 61 exit unless $info; 62 } 61 63 62 # if we have metadata, change the directory name to ARTIST.DATE.ALBUM, so it will sort nicely 63 my $base_dir = (splitpath($DIRECTORY))[1]; 64 if ($ALL) { 65 # if we are converting an entire album file, create a directory to hold the mp3s 66 # name the directory ARTIST.DATE.ALBUM, so it will sort nicely 67 my $base_dir = $DIRECTORY; 64 68 my $album_dir = join('.', map { to_filename($_) } @{$info}{qw{ALBUMARTISTSORT ORIGINALDATE ALBUM}}); 65 69 # need to append "disc#" if this is a multidisc album
Note: See TracChangeset
for help on using the changeset viewer.