Le 26/04/06, Serge Bogaerts<[EMAIL PROTECTED]> a écrit :
> Jérôme Fenal wrote on 04/26/2006 11:07 PM:
>
> >Le 26/04/06, Vincent Pinchart<[EMAIL PROTECTED]> a écrit :
> >
> >
> >>J'ai besoin d'isoler le 'load avg 15m' en une ligne de commande.
> >>
> >>
> >uptime | perl -nle 'print $1 if m/(([\d\.])+)$/'
> >
> >
> Pourquoi pas cela plutôt?
>
> uptime | awk -F, '{print $NF}'

parce qu'il y a une espace surnémaire (et pas numérique) dans le résultat ?

--
Jérôme Fenal - jfenal AT gmail.com - http://fenal.org/
Paris.pm - http://paris.mongueurs.net/
_______________________________________________________
Linux Mailing List - http://www.unixtech.be
Subscribe/Unsubscribe: http://lists.unixtech.be/cgi-bin/mailman/listinfo/linux
Archives: http://www.mail-archive.com/linux@lists.unixtech.be
IRC: chat.unixtech.be:6667 - #unixtech
NNTP: news.gname.org - gmane.org.user-groups.linux.unixtech

Répondre à