按照官方的教程http://www.redmine.org/projects/redmine/wiki/HowTo_Easily_integrate_a_(SSH_secured)_GIT_repository_into_redmine
在centos上安装好了redmine和git.但是按教程的最后一步命令
*/5 * * * * redmine cd /var/lib/redmine/repos/my_repo && git fetch --all
配置完,发现通过redmine无法看到git仓库的最新变化.而如果将git fetch 命令修改为git merge的话,则正常了.不知道有没有用过的开发人员指点一下,确定一下是不是自己配置有问题的.
This is normal.
git fetch
Just capture it, not merge it, nor update your working directory. So your working directory has not changed.If you want to update,
fetch
之后要merge
。(或者fetch
和merge
两步并一步:pull
. )Have you tried executing git fetch manually?
Or give it a try:
git --git-dir='/var/lib/redmine/repos/my_repo' fetch --all
If you use git merge, it is actually only for merging data under the current branch, but redmine does not read these data. If you follow the tutorial and use the --mirror parameter, actually none of the files in your warehouse will be included. It is in the form of a regular file, but what is in the .git directory during regular cloning.