Add preReceive and postReceive hooks