Fixed -0 option in tagfromfilename
This commit is contained in:
parent
f0a348c0ae
commit
0e54174dd7
2
cdripper
2
cdripper
|
@ -41,7 +41,7 @@ $HELP_MSG = "# CD Ripper v$VERSION\n\tusage: cdripper [--no-cddb] [-a] " .
|
|||
"-o [num]:\tOffset track numbers by num. The first track will be num+1\n" .
|
||||
"-y:\t\tDon't prompt for user confirmation of CDDB information\n\t\t(assume defaults are okay).\n" .
|
||||
"--no-cddb:\tDon't use CDDB. Prompt the user for all information.\n" .
|
||||
"-T:\t\tWrite uppercase tag names. Passes -T to tagfromfilename";
|
||||
"-T:\t\tWrite uppercase tag names. Passes -T to tagfromfilename\n";
|
||||
|
||||
$CDPARANOIA_FORMAT = 'track*.cdda';
|
||||
$TRACK_ZERO = 'track00';
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
# 0.1: initial implementation
|
||||
|
||||
$VERSION = "0.2.4";
|
||||
$HELP_MSG = "Vorbiscomment from Filename $VERSION\n\tusage: vcfromfilename [options] <files>\n\nValid options:\n\t-n\tOnly set the track numbers\n\t-0\tPreserve leading 0s in track numbers\n\t-T: Write tag names (not tag content) in all caps";
|
||||
$HELP_MSG = "Vorbiscomment from Filename $VERSION\n\tusage: vcfromfilename [options] <files>\n\nValid options:\n\t-n\tOnly set the track numbers\n\t-0\tPreserve leading 0s in track numbers\n\t-T: Write tag names (not tag content) in all caps\n";
|
||||
|
||||
chomp($COMMENTFILENAME = '/tmp/vcfromfilename-' . `whoami`);
|
||||
|
||||
|
@ -100,7 +100,7 @@ foreach (@ARGV)
|
|||
# Now get the track number
|
||||
my $tracknum = $_;
|
||||
$tracknum =~ s/.*-(\d{2})-.*/\1/;
|
||||
if (!$extrazeros) { $tracknum =~ s/\b0*//; } # removing leading zeros
|
||||
if (!$extrazero) { $tracknum =~ s/\b0*//; } # removing leading zeros
|
||||
$tracknum = formatName($tracknum, 'tracknumber=', $captagnames);
|
||||
print COMMENTFILE $tracknum;
|
||||
|
||||
|
|
Reference in New Issue
Block a user