Hallo, Am Fre, 13 Jun 2008, Felix Lemke schrieb: [..]
if [ "`ls /media/ | grep "device name"`" != "" ]; then
Weia. Noch umständlicher hast du's nicht hinbekommen? Du bekommst dafür trotzdem einen Von-Hinten-durch-die-Brust-ins-Auge-Award in Blech... .----------------------. \ <*> <-. / \ | | / \ ----------' / \ | / \____________/ grep sagt einem doch, ob es was gefunden hat, und 'if' will auch nicht mehr wissen als den Exitcode... Das test ist vollkommen überflüssig. if grep -q '/dev/bla' /proc/mounts ; then if lsusb | grep -q 'IRGENDWAS' ; then und andere Variationen des Themas. -dnh -- Two atoms are walking along. Suddenly, one stops. The other says, "What's wrong?" "I've lost an electron." "Are you sure?" "I'm positive!" -- Um die Liste abzubestellen, schicken Sie eine Mail an: opensuse-de+unsubscribe@opensuse.org Um eine Liste aller verfuegbaren Kommandos zu bekommen, schicken Sie eine Mail an: opensuse-de+help@opensuse.org