]> diplodocus.org Git - flac-archive/blobdiff - fa-tags
(get_decod_args): The third time field is *sectors*, not hundredths of
[flac-archive] / fa-tags
diff --git a/fa-tags b/fa-tags
index d399287bf71805ff276d4f072f38f6efd8895a2e..7d023ec06774d3200b3383f9b16f5b030bb29ec5 100755 (executable)
--- a/fa-tags
+++ b/fa-tags
@@ -7,6 +7,10 @@
 use strict;
 use warnings;
 
+use Env qw(
+           CDDEV
+);
+
 use Getopt::Long;
 use Pod::Usage;
 
@@ -20,7 +24,13 @@ $help and pod2usage(-exitstatus=>0, -verbose=>1);
 
 my $trackcount = shift or pod2usage();
 
-my $mb = new MusicBrainz::Client::Simple;
+my $mb;
+if (defined($CDDEV)) {
+    $mb = new MusicBrainz::Client::Simple (device=>$CDDEV);
+} else {
+    $mb = new MusicBrainz::Client::Simple;
+}
+
 my @result = $mb->lookup_cd;
 die($mb->get_error) unless $mb->success;
 
@@ -36,6 +46,8 @@ for my $album (@result) {
 
     print(F 'ARTIST=', $album->get_artist->get_name, "\n");
     print(F 'ALBUM=', $album->get_name, "\n");
+
+    # MusicBrainz doesn't have dates yet; these are usually wrong anyway.
     print(F "DATE=\n");
 
     my @tracks = $album->get_tracks;