perl -ni.bak -le "print if length $_" my_file.txt