Git pre-commit hook not running on windows

前端 未结 9 1008
盖世英雄少女心
盖世英雄少女心 2021-01-31 08:15

I\'m just starting to look into Git hooks, but I can\'t seem to get them to run.

I set up a local repository, so there is now a \'.git\' directory in my project folder.

9条回答
  •  滥情空心
    2021-01-31 08:53

    What about naming your hook pre-commit (without any extension) ?

    EDIT: and add #!/bin/sh on the first line or #!/bin/bash (suggested in comments)

提交回复
热议问题