Find all files (not directories) in the directory "${HOME:?}/code" that are not empty and move them to a new file with the same name but with the extension ".bak".
find "${HOME:?}/code" -type f ! -empty | xargs -I{} mv {} {}.bak