Gentoo Archives: gentoo-user

From: "Lluís Batlle i Rossell" <viric@××××××××××××××××××.net>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] re-encode mp3 files
Date: Wed, 08 Dec 2004 11:16:40
Message-Id: 20041208111619.GA10027@vicerveza.homeunix.net
In Reply to: Re: [gentoo-user] re-encode mp3 files by "Lluís Batlle i Rossell"
1 Fek. There are doubled lines....
2 I should have kept my mouth shout up. I corrected that.
3
4 On Wed, Dec 08, 2004 at 12:02:51PM +0100, Lluís Batlle i Rossell wrote:
5 > I personaly prefer using a pipe. :)
6 >
7 > Here is my "mp32mp3.sh":
8 #!/bin/bash
9 echo "Converting mp3 to mp3..."
10 if [ $# -lt 2 ]; then
11 echo "Usage: $0 <dest-dir> <abr> <mp3_1> <mp3_2> ..."
12 exit 1
13 fi
14 DEST="$1"
15 ABR="$2"
16 shift
17 shift
18 for a in `seq 1 $#`; do
19 echo "* Converting \"$1\"... "
20 mpg321 -q -w - "$1" | lame --abr $ABR - "$DEST"/"$1"
21 if [ $? = 0 ]; then
22 echo \[done\]
23 else
24 echo failed
25 fi
26 shift
27 done
28 % END
29
30 --
31 gentoo-user@g.o mailing list