Java 如何将 TortoiseSVN 与 Eclipse 一起使用
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/19706159/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
How to use TortoiseSVN together with Eclipse
提问by user1817612
I want to use TortoiseSVN together with Eclipse. For now I just want to try it out. So I use a local folder as repository. I have installed TortoiseSVN 1.7.13. I created a folder called 'REPOSITORY' and chose 'Create repository here' from the context menu.
我想将 TortoiseSVN 与 Eclipse 一起使用。现在我只想尝试一下。所以我使用本地文件夹作为存储库。我已经安装了 TortoiseSVN 1.7.13。我创建了一个名为“REPOSITORY”的文件夹,并从上下文菜单中选择了“在此处创建存储库”。
As other websites told, I installed Subclipse 1.8.22 in Eclipse. I use the SVNKit1.7.9 as client or connector (Whatever it is called).
正如其他网站所说,我在 Eclipse 中安装了 Subclipse 1.8.22。我使用 SVNKit1.7.9 作为客户端或连接器(不管它叫什么)。
I had already some projects in eclipse's workspace. From the context menu I chose 'Team->Share Project'.
我已经在 eclipse 的工作区中有一些项目。从上下文菜单中,我选择了“团队->共享项目”。
That is what other websites told to do.
这是其他网站告诉要做的。
It did show the normal commit dialog and so on. The projects are marked as commited but the folder 'REPOSITORY' is still small in size.
它确实显示了正常的提交对话框等等。项目被标记为已提交,但文件夹“REPOSITORY”的大小仍然很小。
It seems, that the projects where not copied or moved to the repository.
似乎没有复制或移动到存储库的项目。
At work we have a server based SVN. I just want to have something like that at home.
在工作中,我们有一个基于服务器的 SVN。我只想在家里有这样的东西。
Did I miss something? Isn't it the purpose of the SVN repository to hold a copy of the projects? So the commited projects should be inside the REPOSITORY, right?
我错过了什么?SVN存储库的目的不是保存项目的副本吗?所以提交的项目应该在 REPOSITORY 里面,对吧?
Greetings
你好
Mike
麦克风
采纳答案by hqcasanova
Apparently, you have to manually import the project in Eclipse into the repository created with TortoiseSVN before actually committing to it.
显然,在实际提交之前,您必须手动将 Eclipse 中的项目导入到使用 TortoiseSVN 创建的存储库中。
This other pagemight help you. It gives a very detailed walkthrough of how to set up exactly the kind of local system you want. In essence:
这其他页面可能会帮助你。它非常详细地介绍了如何准确设置您想要的本地系统类型。在本质上:
In Eclipse, delete the project but not its contents(
Delete project contents on disk
unchecked). This will leave the project's folder under your workspace location untouched.Outside Eclipse, import the project folder into the repositorypreviously created with TortoiseSVN (
Right click on folder
>TortoiseSVN
>Import
and select the URL of the repository). Once imported, you may wish to delete the project folder.Back in Eclipse, checkout the project from TortoiseSVN's repository(e.g.
Right click on Package Explorer
>Import..
>SVN
>Projects from SVN
).
在 Eclipse 中,删除项目但不删除其内容(
Delete project contents on disk
未选中)。这将使您的工作区位置下的项目文件夹保持不变。在 Eclipse 之外,将项目文件夹导入之前使用 TortoiseSVN 创建的存储库(
Right click on folder
>TortoiseSVN
>Import
并选择存储库的 URL)。导入后,您可能希望删除项目文件夹。返回 Eclipse,从 TortoiseSVN 的存储库(例如
Right click on Package Explorer
>Import..
>SVN
>Projects from SVN
)中检出项目。
Hope that helps.
希望有帮助。
回答by Deniz Beker
If your project's folder structure and package structure are the same, you can use Eclipse Subversive. It's just a plugin for eclipse and provides all features of TortoiseSVN
如果您的项目的文件夹结构和包结构相同,则可以使用Eclipse Subversive。它只是一个eclipse插件,提供了TortoiseSVN的所有功能