#! /bin/bash for f in $(ls ./) do if [[ $(file -b $f | grep "ELF 64-bit") ]] then rm -v $f fi done