码迷,mamicode.com
首页 > 其他好文 > 详细

IDEA git操作 英语

时间:2020-04-30 13:45:03      阅读:100      评论:0      收藏:0      [点我收藏+]

标签:link   ica   margin   color   round   sel   edit   oci   copy   

Manage projects hosted on GitHub 管理托管在GitHub上的项目

Check out a project (clone)  签出项目(克隆)

You can clone a repository that you want to contribute to directly from IntelliJ IDEA and create a new project based on it.

你可以直接从IntelliJ IDEA克隆一个你想要贡献的知识库,并在此基础上创建一个新的项目。

 

1.From the main menu, choose VCS | Checkout from Version Control | Git. 

在主菜单中,从版本控制| Git中选择VCS | Checkout。

2.In the Clone Repository dialog, specify the URL of the repository that you want to clone. You can select a repository from the list of all GitHub projects associated with your account and the organization that your account belongs to. 

在“克隆存储库”对话框中,指定要克隆的存储库的URL。您可以从与您的帐户和您的帐户所属的组织相关联的所有GitHub项目列表中选择一个存储库。

3.In the Directory field, enter the path to the folder where your local Git repository will be created. 

在Directory字段中,输入将创建本地Git存储库的文件夹的路径。

4.Click Clone. If you want to create a project based on these sources, click Yes in the confirmation dialog. IntelliJ IDEA will automatically set Git root mapping to the project root directory. 

单击复制。如果希望基于这些源创建项目,请在确认对话框中单击Yes。IntelliJ IDEA将自动设置Git根映射到项目根目录。

 

Share a project on GitHub

You can add a remote GitHub repository for a project you are developing locally, so that others can view it or contribute to it.

您可以为您在本地开发的项目添加一个远程GitHub存储库,以便其他人可以查看它或对它进行贡献。

 

1.Open the project you want to share.

打开您想要共享的项目。

2.From the main menu, choose VCS | Import into Version Control | Share Project on GitHub.

从主菜单中选择VCS |导入到GitHub上的版本控制|共享项目。

If you have already registered your GitHub account in IntelliJ IDEA, connection will be established using these credentials.

如果你已经在IntelliJ IDEA注册了你的GitHub账户,那么就可以使用这些凭证建立连接。

If you have not registered your account in IntelliJ IDEA, the Login to GitHub dialog opens. Specify your access token or request a new one with your login and password.

如果你还没有在IntelliJ IDEA注册你的帐号,登录到GitHub的对话框就会打开。指定您的访问令牌或使用您的登录名和密码请求一个新的令牌。

3.When connection to GitHub has been established, the Share Project on GitHub dialog opens. Specify the new repository name, the name of the remote, and enter a description of your project.

当连接到GitHub时,GitHub对话框上的共享项目就会打开。指定新的存储库名称、远程的名称,并输入项目的描述。

You can select the Private option if you do not want to allow public access to your repository for other GitHub users (note that this option is unavailable for free accounts).

如果您不想让其他GitHub用户访问您的存储库,您可以选择Private选项(注意,这个选项对于免费帐户是不可用的)。

4.Click Share to initiate a new repository and upload project sources to it.

单击共享启动一个新的存储库,并将项目源代码上载到其中。

 

 

Jump to the GitHub version of a file  

跳转到文件的GitHub版本

You can jump from IntelliJ IDEA to the GitHub version of a file. IntelliJ IDEA detects which branch is currently active as well as the latest revision of the file, and opens the GitHub copy of the selected file in the corresponding commit in your web browser. If you are opening the GitHub file version from the editor, the file will be also automatically scrolled to the current line.

你可以从IntelliJ IDEA跳到一个文件的GitHub版本。IntelliJ IDEA检测哪个分支当前处于活动状态以及文件的最新版本,并在web浏览器的相应提交中打开所选文件的GitHub副本。如果您从编辑器中打开GitHub文件版本,该文件也会自动滚动到当前行。

1.Select a file in the editor or in the Project view, and choose Open on GitHub from the context menu or from the Ctrl+Shift+A popup. The remote version of the file will open in the browser.

在编辑器或项目视图中选择一个文件,然后从上下文菜单或Ctrl+Shift+ a弹出菜单中选择GitHub上的Open。文件的远程版本将在浏览器中打开。

2.If the file points to more than one remote, you will be prompted to select the appropriate repository.

如果文件指向多个远程,系统将提示您选择适当的存储库。

 

 

 

 

Jump to the GitHub version of a file

IDEA git操作 英语

标签:link   ica   margin   color   round   sel   edit   oci   copy   

原文地址:https://www.cnblogs.com/cmdzhizhu/p/12808188.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!