Reputation: 23
Good afternoon. My script should find files with the size less than the second argument ($fsize). At the same time it should ignore files with .sh extension. (Actually, it shouldn't find file of the running script. If you prompt me how to realize it, it would me excellent). So could you help me? Here is my vision of this, but it doesn't work.
find -type -f -size -$fsize -and -not -name *.sh
Upvotes: 0
Views: 335
Reputation: 1482
Try this :
find ./ -type f -size -$fsize -and -not -name '*.sh'
Upvotes: 3