草庐IT

branching

全部标签

git - 在 filter-branch --tree-filter 之后从 git repo 中删除 refs/original/heads/master?

我在这里遇到了同样的问题:Newgitrepositoryinrootdirectorytosubsumeanexistrepositoryinasub-directory我在这里遵循了这个答案:Newgitrepositoryinrootdirectorytosubsumeanexistrepositoryinasub-directory现在,gitk--all显示两个历史:一个以当前master结束,另一个名为original/refs/heads/master.我不知道第二个历史是什么,也不知道如何将其从存储库中删除。我的存储库中不需要两个历史记录。我该如何摆脱它?复制自己:mk

git - 在 filter-branch --tree-filter 之后从 git repo 中删除 refs/original/heads/master?

我在这里遇到了同样的问题:Newgitrepositoryinrootdirectorytosubsumeanexistrepositoryinasub-directory我在这里遵循了这个答案:Newgitrepositoryinrootdirectorytosubsumeanexistrepositoryinasub-directory现在,gitk--all显示两个历史:一个以当前master结束,另一个名为original/refs/heads/master.我不知道第二个历史是什么,也不知道如何将其从存储库中删除。我的存储库中不需要两个历史记录。我该如何摆脱它?复制自己:mk

git - 在git branch中获取所有修改过的文件

有没有办法查看分支中哪些文件发生了变化? 最佳答案 @MarcoPonti的答案的替代方案,并避免checkout:gitdiff--name-only$(gitmerge-base)如果您的特定shell不理解$()构造,请改用反引号。 关于git-在gitbranch中获取所有修改过的文件,我们在StackOverflow上找到一个类似的问题: https://stackoverflow.com/questions/10641361/

git - 在git branch中获取所有修改过的文件

有没有办法查看分支中哪些文件发生了变化? 最佳答案 @MarcoPonti的答案的替代方案,并避免checkout:gitdiff--name-only$(gitmerge-base)如果您的特定shell不理解$()构造,请改用反引号。 关于git-在gitbranch中获取所有修改过的文件,我们在StackOverflow上找到一个类似的问题: https://stackoverflow.com/questions/10641361/

Git 推送错误 : refusing to update checked out branch

我已经解决了一些merge冲突,提交然后尝试推送我的更改并收到以下错误:c:\ProgramFiles(x86)\Git\bin\git.exepush--recurse-submodules=check"origin"master:masterDoneremote:error:refusingtoupdatecheckedoutbranch:refs/heads/masterremote:error:Bydefault,updatingthecurrentbranchinanon-barerepositoryremote:error:isdenied,becauseitwillmak

Git 推送错误 : refusing to update checked out branch

我已经解决了一些merge冲突,提交然后尝试推送我的更改并收到以下错误:c:\ProgramFiles(x86)\Git\bin\git.exepush--recurse-submodules=check"origin"master:masterDoneremote:error:refusingtoupdatecheckedoutbranch:refs/heads/masterremote:error:Bydefault,updatingthecurrentbranchinanon-barerepositoryremote:error:isdenied,becauseitwillmak

git - "git branch"和 "git checkout -b"有什么区别?

我使用gitcheckout-b创建了一个新分支。我认为gitbranch做同样的事情。如果这两个命令完全不同,它们有何不同? 最佳答案 gitcheckout-bBRANCH_NAME创建一个新分支并checkout新分支,而gitbranchBRANCH_NAME创建一个新分支但将您留在同一分支上。换句话说,gitcheckout-bBRANCH_NAME为您执行以下操作。gitbranchBRANCH_NAME#createanewbranchgitswitchBRANCH_NAME#thenswitchtothenewbra

git - "git branch"和 "git checkout -b"有什么区别?

我使用gitcheckout-b创建了一个新分支。我认为gitbranch做同样的事情。如果这两个命令完全不同,它们有何不同? 最佳答案 gitcheckout-bBRANCH_NAME创建一个新分支并checkout新分支,而gitbranchBRANCH_NAME创建一个新分支但将您留在同一分支上。换句话说,gitcheckout-bBRANCH_NAME为您执行以下操作。gitbranchBRANCH_NAME#createanewbranchgitswitchBRANCH_NAME#thenswitchtothenewbra

git - 致命的 : The current branch master has no upstream branch

我正在尝试将我的一个项目推送到github,但我一直收到此错误:peeplesoft@jane3:~/846156(master)$gitpushfatal:Thecurrentbranchmasterhasnoupstreambranch.Topushthecurrentbranchandsettheremoteasupstream,usegitpush--set-upstreamoriginmaster所以我试了一下,得到了这个:peeplesoft@jane3:~/846156(master)$gitpush--set-upstreamoriginmasterfatal:Auth

git - 致命的 : The current branch master has no upstream branch

我正在尝试将我的一个项目推送到github,但我一直收到此错误:peeplesoft@jane3:~/846156(master)$gitpushfatal:Thecurrentbranchmasterhasnoupstreambranch.Topushthecurrentbranchandsettheremoteasupstream,usegitpush--set-upstreamoriginmaster所以我试了一下,得到了这个:peeplesoft@jane3:~/846156(master)$gitpush--set-upstreamoriginmasterfatal:Auth