标签:out end push 问题 led 一起 gitolite 更改 style
如果gitolite原来的管理员已经没了,那么需要把当前的公钥放到服务器覆盖,然后替换目录下.ssh/authorized_keys内容
warning: inexact rename detection was skipped due to too many files.
warning: you may want to set your diff.renameLimit variable to at least 19371 and retry the command.
解决方案:
You need to set and unset that rename limit:
git config merge.renameLimit 999999 //这一条就可以用,下面这条没有用到 git config --unset merge.renameLimit
gitignore
里面的忽略规则是顺序的,比如上面不忽略txt,下面再写入忽略a.txt,那么a.txt就会被忽略
把两个不同的仓库合并到一起
$ git remote -v origin git@192.168.1.1:lib.git (fetch) origin git@192.168.1.1:lib.git (push) $ git remote -v origin git@192.168.1.1:pro.git (fetch) origin git@192.168.1.1:pro.git (push)
把lib合并到pro
$ git remote add slib git@192.168.1.1:lib.git
在pro的分支下运行上面的命令,把lib远程仓库添加到pro下,昵称是slib
$ git fetch slib
把代码拉到本地
$ git checkout -b test slib/master
把本地拉取的lib的仓库,切换到一个test分支,防止合并冲突不好解决
$ git checkout prodev Checking out files: 100% (14522/14522), done. Switched to branch ‘prodev‘
切回到pro的一个分支
$ git merge test
fatal: refusing to merge unrelated histories
把test merge过来,就可以了,可能会有上面错误
$ git merge test --allow-unrelated-histories Auto-merging .gitignore CONFLICT (add/add): Merge conflict in .gitignore Automatic merge failed; fix conflicts and then commit the result.
添加上面命令,强制merge过来
解决冲突提交,就可以了
git commit --amend 重新提交,更改提交日志
gitignore忽略文件夹下的所有文件,但是排除某些目录
先不忽略目录
!application/
再忽略目录下的所有文件
application/*
再屏蔽不忽略的目录
!application/language/
拆分仓库
标签:out end push 问题 led 一起 gitolite 更改 style
原文地址:https://www.cnblogs.com/studywithallofyou/p/11356482.html