[LUGOS] bash vprasanje

Gorazd Brumen gorazd.brumen at fmf.uni-lj.si
Sun Feb 8 20:54:14 CET 2004


 > -      mplayer $i -ao pcm -aofile $j ;
 > +      mplayer "$i" -ao pcm -aofile "$j";

Ne, zal ne bo drzalo. Problem je ko ls zlista
datoteke in dobis
01 - fajl1.mp3 02 - fajl2.mp3 03 - fajl3.mp3 04 - fajl4.mp3

Kolikor sem jaz dojel, potem zavzame i po vrsti vrednosti
01
-
fajl1.mp3
02
-
fajl2.mp3

itd.

Problem je prej v tem kako prepricat ls da bi namesto _ (presledka)
naredil nekaj v stilu \_ (backslash presledek).

Gorazd


#!/bin/bash
for i in $( ls $1 ); do
     j=`echo $i | awk -F"." '{print $1 ".wav"}'`
     mplayer "$i" -ao pcm -aofile "$j" ;
done


Jure Pečar wrote:
> On Sun, 08 Feb 2004 20:25:28 +0100
> Gorazd Brumen <gorazd.brumen at fmf.uni-lj.si> wrote:
> 
> 

-- 
Mail 1: brumen at isb.unizh.ch
Mail 2: gorazd.brumen at fmf.uni-lj.si
Homepage: valjhun.fmf.uni-lj.si/~brumen



More information about the lugos-list mailing list