English 中文(简体)
前往空间+GIT
原标题:Tabs to spaces + GIT
  • 时间:2011-11-11 13:54:08
  •  标签:
  • git

我与几个其他开发商合作开展一个项目。 并非每个人都使用相同的发展信息网。 最近,我认识到,法典的某些部分有表格,有些有空间。 一切都看着K在使用表格=4个空间显示代码时,但它确实与其他环境相差。

We are using git as VCS. Is there any way to reformat entire code in repository, commit those changes AND preserve "blame information" somehow?

最佳回答

没有重写历史,这是不可能的。

最容易和最易于发展的解决办法(通过获取责任信息而获得这种信息)正在把所有白天空问题放在一个单一承诺中,然后将灰质混为一谈,以拒绝增加混血。

如果重写历史不是你的问题(例如,你可以要求所有开发商放弃其地方分支机构和改写的分支),你可能会使用<条码>git滤-branch<来固定白空间。 这将不是一项新承诺,因此,确保<代码>git charge<>/code>在变更后显示正确的信息。

问题回答

您可以写出自己的文字,用所希望的空间(如你有4个)取代表格,并将其放在<代码>.git/hooks/pre-commit。

简单的印本可以取代每张纸张到4个空间,但每次承诺之前都必须使用。

或者,研究不同杀手的环境,而不是使用禁忌。 我知道,教授可以这样做。





相关问题
git confusion - cloning a repo is returning a past version

Im having some confusion with my git usage. I cloned a repo from one comp to the other, and the new clone is the state of the original that was active some time ago. So its cloning a past version. ...

Appropriate strategy for tagging and hotfixing with git

I was wondering if the strategy I m using for tagging and hotfixing tags (which then I use for deploying rails applications) with git is appropriate. For tagging I just tag a commit of the master ...

Tips on upgrading CVS to git/hg?

We still use CVS, I use git and hg for my personal use though I m still a novice at both, but I realize they re much more modern and better, faster, distributed, etc. It s just everyone is so ...

Using Git in a TFS shop

Using Git at home has spoiled me - I now find using TFS at work to be a bit of a drag and want to explore the possibility of using Git locally and syncing somehow with TFS. I figure there are a few ...

热门标签