English 中文(简体)
我如何去掉一个空洞的夹子,推动这一变化?
原标题:How do I remove an empty folder and push that change?

我怎么能在当地清除一只空洞的夹子,如果其他合作者通过拉普什偏僻,情况如何? 我知道,从这个意义上讲,有双管齐下,但问题依然存在。

例如,我把一个档案转移到另一个文件夹,并承诺改变(搬迁)。

But I can t git rm name the folder as I get "doesn t match" git rmdir name doesn t exist.

我能做一个<条码>干净——f 倍,但如何推进?

页: 1 档案材料,但我如何正确清除该名录,并将其推向存放处,然后将其现有文件夹删除。

最佳回答

简短的答复: 你可以推动对名录的改动(增加、删除等),因为Gite没有跟踪自己的目录。

根据FAQ:

目前,盖特指数(老区)的设计只允许将档案列入清单,任何人都无权作出这一改动,以允许空局对这一情况给予足够的关注,以加以补救。

在内部增加档案时,自动添加名录。 也就是说,目录永远不必添加到存放处,而且不能自行跟踪。

So as far as Git is concerned, your empty directory doesn t exist anymore.

我发现,在使用<代码>git Clean -fd的习惯上,没有必要推动撤销名录。 然而,git Clean 您不希望删除的项目(包括你尚未承诺的新档案),因此,我倾向于首先使用<代码>git Clean -fdn,以便在我使用指挥时看到删除will的内容。

It looks like you may be forced to talk to your fellow developers in order to clean up that directory.

问题回答
git add --all
git clean -f -d
git commit -m "trying to remove folders"
git push

你们可以推倒空洞的夹。 但是,如果你想要清除你衣着/当地背书上的空洞fold,你就会作出最新改变。 那么,除了在当地复制件外,所有档案都删除。 随后又重新开始所有改动,将所有档案都重新整理,但留下空洞的目录。





相关问题
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 ...