简体   繁体   English

Git承诺在网站上现场直播

[英]Git commits to show live on website

So I have a bitbucket repository I push my code to. 所以我有一个我将代码推送到的bitbucket存储库。 How can I hook up my repository and have it so that anything that gets committed shows on my site? 如何连接我的存储库并拥有它,以便任何提交的内容都能在我的网站上显示?

In this link https://confluence.atlassian.com/display/BITBUCKET/Manage+Bitbucket+hooks you can find a documentation on how to add a hook. 在此链接https://confluence.atlassian.com/display/BITBUCKET/Manage+Bitbucket+hooks中,您可以找到有关如何添加挂钩的文档。 Add a POST hook to call a url on your server. 添加POST挂钩以在服务器上调用网址。 This url should point to a script (PHP for example) to git pull, check this blog post http://jondavidjohn.com/git-pull-from-a-php-script-not-so-simple . 该网址应指向git pull脚本(例如PHP),请查看此博客文章http://jondavidjohn.com/git-pull-from-a-php-script-not-so-simple

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM