从 IDE 外部进行版本控制是一种好习惯吗? [英] Is it a good practise to do version control from outside the IDE?

查看:26
本文介绍了从 IDE 外部进行版本控制是一种好习惯吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我不止一次从同行那里听说这是建议"的.不要在编写代码的 IDE 中对代码进行版本控制.我见过他们在 Eclipse, IntelliJ IDEA 等,但从命令行或独立客户端进行版本控制(在我当前的场景中 - Git)而不是使用相应的插件可用于 IDE.

I have heard from my peers on more than one occasion that it is "advised" not to do version controlling of your code from within the IDE where you write it. I have seen them developing on Eclipse, IntelliJ IDEA, etc. but doing version control (in my current scenario - Git) from command-line or standalone clients as opposed to using the corresponding plugins readily available for the IDE.

虽然我在 Eclipse 中使用过版本控制插件并且从未发现任何问题,但我想知道一般规范是什么以及为什么?

Though I have used version control plugins in Eclipse and never found any issues, I would like to know what is the general norm and why?

推荐答案

我不认为有一个普遍的规范.这个问题的答案非常主观.

I don't think that there's a general norm. The answer to the question is highly subjective.

我个人不使用任何 IDE 集成(甚至没有 GUI 工具,除了内置的 git guigitk),因为我的经验告诉我这些工具行为不同于命令行版本和/或不提供命令行上可用的全部功能:

I personally don't use any IDE integration (not even a GUI tool, except the builtin ones git gui and gitk) because my experience told me that these tools behave different than the command line version and/or don't provide the full functionality available on the command line:

另一件事是,您对版本控制工具的了解与您的 IDE 密切相关.除了使用 Eclipse 编辑的源(例如,您的点文件)之外,您可能还想为其他内容设置一些版本管理.

Another thing is that your knowledge about your versioning tools is bound to your IDE. Maybe you want to set up some version management for other things than the sources you edit with Eclipse (your dotfiles, for example).

或者有一天您切换 IDE,放弃 Eclipse 并开始使用 Visual Studio.那么你不仅要学习Visual Studio,还需要学习VS中的Git集成.

Or one day you switch your IDE, drop Eclipse and start using Visual Studio. Then you don't have to learn only Visual Studio but in addition you need to learn the Git integration in VS too.

我认为与我上面所写的内容相比,在 IDE 内部合法使用版本控制工具并没有明显的优势.

I think compared with what I've written above, there are no serious advantages that would legitimate the usage of version control tools from inside the IDE.

所以,IMO,内部IDE进行版本控制是一种不好的做法,并且应该始终从外面.

So, IMO, it's a bad practice to do version control from inside the IDE and it should always be done from the outside.

这篇关于从 IDE 外部进行版本控制是一种好习惯吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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