删除git分支会失去审计 [英] Deleting git branch loses audit

查看:160
本文介绍了删除git分支会失去审计的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如果在git中删除了一个分支,是否仍然可以确定是否在该删除的分支上进行了特定的提交?

从我迄今发现的 - git分支仅仅是指针,所以删除它们会丢失审计历史的特定部分。



感谢,



git分支仅仅是指针




p>是的,而这正是删除它们只会删除指针的原因。



如果已将分支合并到主线,则不再需要该指针;但您一定会知道所有提交到该分支的个别情况,除非您通过要求快速合并来明确选择不知道具体更改。


If a branch has been deleted in git is it still possible to identify whether specific commits were made on that deleted branch?

From what I have found so far - git branches are merely pointers so deleting them would lose the that specific part of the audit history.

Hoping that I can be proven wrong on this.

thanks,

解决方案

git branches are merely pointers

Yes and which is exactly why deleting them would delete just the pointer.

If you have merged the branch to your mainline, you no longer need that pointer; but you will always know what all commits were made to that branch individually, unless you explicitly choose to not know the specific changes by asking for a fast-forward merge.

这篇关于删除git分支会失去审计的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆