rename.sh updated, testing function added