IDEA share the project to Git @ OSC, ideagit @ osc
Prerequisites: to create a new project, you must create a version library in Git @ OSC.
1. Of course, you should first create a repository on Git @ OSC and get the HTTP Connection of Git @ OSC repository https://git.oschina.net/####/###.git
2. If our local project is not a git project, we need to convert it into a git project first.
In idea, VCS -- Import into Version Control -- Create Git Repository -- select your local project
3. Use git shell (you can install git for window) to enter the project directory and execute the following command
# Setting up a remote repository for the Project # git remote add origin http://git.oschina.net/#####/####git# capturing remote repository data, and automatically merge remote branches # git pull origin master # update local data to Git @ OSC # git push origin master # solve the problem that cannot be updated git branch -- set-upstream master
If pull or push fails, please refer to the git prompt to solve, refer to blog: http://blog.csdn.net/dengjianqiang2011/article/details/9260435
If the above operations have a variety of inexplicable problems, and there is no decent solution on the Internet, there is another way:
1. Create a local folder and clone the project above Git @ OSC to this folder;
2. Import the data to IDEA or other development tools.