This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Pegar o retorno de uma listagem obtida pelo GREP, lê o conteúdo de cada arquivo da listagem e gravar em outro arquivo | |
for i in `grep -l "TEXTO" /pasta/arquivo(s)`; do | |
cat $i >> destino.txt ; | |
done | |
Monitorar uma Listagem de Arquivos em um Diretório | |
while [ 1 ]; do clear; ls -l;sleep 1; done; | |
Pesquisar e mover arquivos criados/modificados ha mais de quatro dias | |
$ find . -mtime +4 -exec mv {} temp/ \; |