[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Script



Ok... Gracias a los que me contestaron..., me quedo asi:

#!/bin/sh

        for user in `cat /tmp/excedidos` {
do
        grep ^$user /etc/passwd | awk -F: '{print $5"-->"$1}' 
done


El mar, 20-05-2003 a las 15:58, Hue-Bond escribió:
> Saxa Egea, Tue20030520@16:49:33(+0200):
> >
> >		cat /etc/passwd | grep -v grep | grep ^$user | awk -F\# {'print $5'}
> 
> Diría que el "grep -v grep" aquí no es necesario ya que esto no es un
> listado de procesos. Además, todavía se puede uno ahorrar un proceso más
> eliminando el cat:
> 
> grep ^$user /etc/passwd | awk -F\# {'print $5'}
> 
> 
> -- 
>  David Serrano - Linux Registered User #87069
> 
> 
> -- 
> To UNSUBSCRIBE, email to debian-user-spanish-request@lists.debian.org
> with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org




Reply to: