Mailinglist Archive: opensuse (671 mails)
| < Previous | Next > |
Re: [opensuse] mp3info help
- From: benefici@xxxxxxxxxxx
- Date: Wed, 8 Jun 2011 10:38:57 +0200
- Message-id: <201106081038.58044.benefici@fastmail.fm>
On Wednesday 08 Jun 2011 01:40:04 Gary Hodder wrote:
The command below does not use mp3info as I don't have it installed, but it
does the job for me:
file "dirname"/* | awk 'BEGIN {total=bad=0} /contains: MPEG ADTS, layer III/ {
x=match($0, "^([^:]+):.*, ([0-9]+) kbps,", a); total++; if(x>0 && a[2]<192)
{bad++}} END {print total, bad}'
Replace dirname with the name of the directory you want to scan (keep the
quotes around the name so that special characters don't cause a problem).
One more thing: I assumed by "number of files in a directory" you meant
"number of mp3 files in a directory".
Tom
--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx
can somebody help me with a script using mp3info that will only print
out number of files in a directory and number of files with a bit rate
of less than 192k.
The command below does not use mp3info as I don't have it installed, but it
does the job for me:
file "dirname"/* | awk 'BEGIN {total=bad=0} /contains: MPEG ADTS, layer III/ {
x=match($0, "^([^:]+):.*, ([0-9]+) kbps,", a); total++; if(x>0 && a[2]<192)
{bad++}} END {print total, bad}'
Replace dirname with the name of the directory you want to scan (keep the
quotes around the name so that special characters don't cause a problem).
One more thing: I assumed by "number of files in a directory" you meant
"number of mp3 files in a directory".
Tom
--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx
| < Previous | Next > |