Was trying to cat /dev/random to all the files in a directory. Tried the usual find exec way as given below, but went futile,
find -maxdepth 1 -type f -iname *.bin -exec cat /dev/random | head -n1024 > {} \;
Tried xargs way, find -maxdepth 1 -type f -print0 | xargs -0 -n1 -i{} cat /dev/random | head -n 1024 > {}
, but that too went south, any idea??
Aucun commentaire:
Enregistrer un commentaire