idea git integration tool

1, idea git integration tool

  1. Install git tools
  2. Open the idea of ​​configuration options, shortcut keys ctrl + alt + s or using click File and then select the settings option
  3. Select the git version control in setting the path selection tool you git installed git.exe (the default automatic loading) PS: There are two git.exe below this you can arbitrarily select one.

  4. Select OK git tool to integrate better.

2, IDEA how to use git push to a remote repository project

  1. A cloud application code or github account (in yards below the clouds, for example)
  2. Ssh own public key on github code and configuration to the cloud (for authentication)
  3. Create a new warehouse in the cloud code
  4. Click vcs (version control) on the navigation bar at the idea of ​​them
  5. Select the figure below blue checked (to create a local git repository) and then select the path to confirm your project
  6. Click the blue column will select the file you want to upload and click the right click option git add will save you want to upload files to the staging area of ​​git
  7. Just put the git staging area file submission (red circled message after you submit) click on the button commint
  8. Select the remote address of the warehouse Click below to upload the selected place blue
  9. Click on the + sign just created a cloud of code added to warehouse inside ps: he had just written the url in the warehouse can be created that address
  10. Select blue below the selected place finish after completion of local projects pushed to the remote repository.

3, for the first time pushed to the remote repository is denied how to solve

  1. I was first given the following chart
  2. Error information indicates a version mismatch remote warehouse and local warehouse
  3. Click below blue selected place
  4. Still being given in the following figure ps: show refused to merge unrelated history
  5. Open the root directory of your project is located (that is, your local repository directory) click to open the git bash command execution
    Origin Master --allow pull-git-UNRELATED Histories    PS : This command allows the combined amount of the two unrelated documents

     

  6. Then Click the blue place (resubmitted to a remote repository)
  7. Success message is displayed

4、idea如何从远程仓库克隆代码

  1. 在idea的初始界面选则check out from version Control中的git选项
  2. 在下个界面分别填入你的git仓库地址 父目录路径 以及文件目录路径   ps:只需要填入远程仓库的地址就可以了 其他两个目录路径自动生成好了当然你也可以自己修改
  3. 接下来就根据idea的提示一步步继续就可以了。

ps:第一次写这个 有啥问题还请多多指教

 

       

 

Guess you like

Origin www.cnblogs.com/ErNan/p/11260050.html
Recommended