Git pre-commit hook not running on windows

前端 未结 9 873
盖世英雄少女心
盖世英雄少女心 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:46

    For me, I tried to run a .bat file.

    I discovered that backslashes need to be escaped:

    For example:

    #!/bin/bash
    C:\\somefolder\\somefile.bat
    

提交回复
热议问题