Use git command to upload the code to the code cloud

The distal end of the case without a project to establish a connection and code says:

  1. Click the "New Project" in the code cloud;
    2. After successfully created, create a local folder or file name of the command mkdir +
    3. The command cd + files into the directory the file name
    4. command to initialize git repository git init
    5. command git remote add origin + warehouse address (the code point cloud into new projects clone or copy the link)
    [Note: there may be fatal:. remote origin already exists error, input solutions "git remote rm origin"]
    6. command git pull origin master (to pull a file on a branch down)
    7. to upload the project file into the newly created folder
    8. the command git add. git add + or being dragged into the project name (to save the cache )
    9. command git commit -m "contents to be edited" (pushed to the local library)
    10. the command git push origin master (i.e. pushed to the distal end of the warehouse on the cloud code)

There are cases of distal project to establish a connection and code says:

1. Create a local folder or command mkdir + file name
2. command cd + files into the directory the file name
3.git clone + code cloud warehouse address

Published 30 original articles · won praise 8 · views 20000 +

Guess you like

Origin blog.csdn.net/wg22222222/article/details/98460253