Revert "checking for dry run option before running hooks."

This reverts commit a5ace1a63daa44f04dcaad0f0cbdfa28be124545.
adding check for dry-run option back

reverted initial commit to get rid of test changes, which were included
accidentally