#!/bin/bash #Benjamyn Love 2017 #finds and renames all .htaccess files to .htaccess.vipback (This name is to avoid clobbering client .htaccess backups) #run in users home directory not anywhere else #TODO add the homedir check if [[ "$PWD" == *"home/"?* ]]; then; echo 1; else echo 0; fi if [[ "$PWD" == "/home"?* ]];then find . -name ".htaccess" -exec mv -v {} {}.vipback \;;else echo "Not in users home directory";fi