我之前一般都是 hooks/下面做一个 post-receive 。并且设定权限 777
这次帮朋友的 VPS 配置 GIT 却发现根本没有 post-receive.sample 。于是我自己建立了一个 post-receive 并且想往常一样输入内容,设定权限,却发现完全不 work 。 gg 了一下,也没找到解决方案。请问有没有类似经验的同学指点一下
hooks/下面的文件如图:(post-receive是我新建的)
PHP中文网2017-05-02 09:25:11
pre-receive
is executed first when the client pushes, and can be used to reject the client's push.
update
is similar to pre-receive, but will be executed once for each branch.
post-receive
Executed after the client push is completed.
曾经蜡笔没有小新2017-05-02 09:25:11
I also asked this question, and someone gave me the answer /q/1010000004382023
It is indeed the case... Create a new document directly to write the content, save it, and then chmod +x post-receive to ensure that it is executable...