Adjusting hooks script for linux compatibility.