[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [shell-script] atribuir variável ao resultado do find
From: |
Herbert P Fortes Neto |
Subject: |
Re: [shell-script] atribuir variável ao resultado do find |
Date: |
Thu, 1 Feb 2007 15:55:57 -0200 |
On Thu, 1 Feb 2007 13:36:56 -0200
"Tiago Barcellos Peczenyj" <address@hidden> wrote:
> acho q o que esta faltando é isto:
>
> LIST=( $(find /var/lib/myphpmoney/ -name \*ereg) )
Isto está funcionando bem
LIST=$(find /var/lib/myphpmoney/ -name \*ereg)
O que quero saber é se dá para substituir o laço for.
Por exemplo para apenas mover:
-exec mv {} /path/para/aqui \;
Como ficaria
-exec diff -u ?
> On 2/1/07, Herbert P Fortes Neto <address@hidden> wrote:
> >
> > ---------------------------------------------------
> > #!/bin/bash
> >
> > LIST=$(find /var/lib/myphpmoney/ -name \*ereg)
> >
> > for i in ${LIST[*]}
> > do
> > diff -u $i ${i//.ereg/} >> myphpmoney.diffs
> > done
> >
> > exit 0
> > ----------------------------------------------------
[]
--
Herbert Parentes Fortes Neto (hpfn)
Linux user number 416100
0x9834F79E -- http://pgp.mit.edu/
[As partes desta mensagem que não continham texto foram removidas]
- atribuir variável ao resultado do find, Herbert P Fortes Neto, 2007/02/01
- Re: [shell-script] atribuir variável ao resultado do find, Tiago Barcellos Peczenyj, 2007/02/01
- Re: [shell-script] atribuir variável ao resultado do find,
Herbert P Fortes Neto <=
- Message not available
- Fwd: [shell-script] atribuir variável ao resultado do find, Julio C. Neves, 2007/02/01
- Re: Fwd: [shell-script] atribuir variável ao resultado do find, Herbert P Fortes Neto, 2007/02/02
- Re: Fwd: [shell-script] atribuir variável ao resultado do find, Julio C. Neves, 2007/02/02
- Re: Fwd: [shell-script] atribuir variável ao resultado do find, Herbert P Fortes Neto, 2007/02/03
- Message not available
- Re: Fwd: [shell-script] atribuir variável ao resultado do find, Julio C. Neves, 2007/02/04
- Re: Fwd: [shell-script] atribuir variável ao resultado do find, Herbert P Fortes Neto, 2007/02/05