How to git it from a remote library clones, create, view, and delete branches

 

Several blog before, we learned how to submit to the local repository to upload files; and the local repository associated with the remote warehouse; today we learn how to clone from a remote repository.

                                 First, cloning

  1. We create a new warehouse

    . The difference is that with before we checked Initialize ........ README allow cloned from the warehouse to the local computer.
  2. Type git clone github URL you want to clone libraries , you can clone me to my web site, for example, my website is https://github.com/2992789432/-zaibendicangku-kelong-

  3. Then type the pwd look at the file location to the corresponding location to find it, you can see the files you clone

                            Second, create a branch 

In the version of the backfill back, you already know that each commit, Git regard they strung together a timeline, this timeline is a branch. Up to now, only one timeline, in Git, this branch is called the main branch, that is, the master branch. HEAD strictly speaking is not directed to submit, but point to the master, master is the point of submission, so, HEAD is pointing to the current branch.

  1. First we create a dev branch. Type git checgitkout -b dev (do not tell revoked before the change confused), to create a dev branch
  2. Then we see the type git branch branch, we can see already our branch list them all, and there will be a current branch in front *

  3. Delete branch type git branch -d example

 If my article helped you remember a point like this, if you are interested to learn together, explore, remember to focus on me, I QQ: 2992789432.

      

Published 45 original articles · won praise 96 · views 10000 +

Guess you like

Origin blog.csdn.net/qq_40831778/article/details/102513593