创建post-receive文件
问题描述:
我正在尝试将我的hostgator配置为使用git。创建post-receive文件
我已经按照这个steps
但在我的.git /挂钩文件夹,这是没有人后领取。
只需将文件:
./ post-update.sample* prepare-commit-msg.sample*
../ pre-applypatch.sample* update.sample*
applypatch-msg.sample* pre-commit.sample*
commit-msg.sample* pre-rebase.sample*
我怎样才能创建一个后收到的文件?
韩国社交协会
答
虽然目前还没有一个样品后收到钩,你可以通过创建.git/hooks
目录中的文件post-receive
创建一个。您可以使用任何文本编辑器来完成此操作,例如nano
或vi
(例如nano .git/hooks/post-receive
)。
为了使钩子正常工作,您还需要将其设置为可执行文件,您可以使用chmod +x .git/hooks/post-receive
执行此操作。