[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [shell-script] awk e maiúsculas
From: |
Gentil de Bortoli Jr |
Subject: |
Re: [shell-script] awk e maiúsculas |
Date: |
Tue, 08 Nov 2005 10:03:29 -0200 |
User-agent: |
Thunderbird 1.4.1 (X11/20051006) |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Mauricy, como não sei qual é a dimensão do seu problema, vou dar uma
solução mais "especialista". Você pediu awk, mas eu ofereço egrep.
Se você quiser apenas imprimir as linhas que começam com letras
maiúsculas, você pode também fazer algo assim:
egrep '^[A-Z]' Arquivo.txt
Depois, talvez um cut possa ser um incremento a mais.
[]s
- --
Gentil de Bortoli Júnior
http://gentil.bortoli.com.br
KeyID: 0x8383E070 - www.keyserver.net
"There Is No Gene For The Human Spirit"
Mauricy Maiorino wrote:
> Como codifico no awk '{print $1}' somente se estiver em
> maiúsculo?? Um trecho do arquivo:
>
>
> ANAGABOS 2005 14:08:29 hpdocuprintr_-CCUEC-ALA- 0001000013bin O2859
> amorim 14:08:57 hpdocuprintr_ifch-I-FIL- 0001000012bin O2747 ifch 1
> AMORIM 2005 14:09:32 hpdocuprintr_ifch-I-FIL- 0001000007bin O2447
> MANDALA 2005 14:10:10 hpdocuprintr_ia-INST-DE- 0001000027bin O2983
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
iD8DBQFDcJQRU6AHyoOD4HARAmOvAKCfhHv+ahws0bYfE4MG3Uh9uUMnmwCghGOS
fsU5DXAqruiTOReS/fLiZsA=
=1jg6
-----END PGP SIGNATURE-----