[hooks] Only handle commits on the master branch.