Git - git clone - 將遠端倉庫克隆拷貝到本地

索引:html

目錄索引git

參看代碼 GitHub:github

git.txtspa

1、示例:code

1 git clone https://github.com/liumeng0403/lm.solution.git

2、說明:htm

  1."clone" 部分blog

    該部分指明是對遠端已存在倉庫的克隆動做,遠端倉庫被克隆到本地後,在本地就是一個git倉庫,索引

    而且這個git倉庫自動默認追蹤克隆過來的遠端倉庫,如 local:dev-->remote:dev、local:master-->remote:master 等等。rem

  2."https://github.com/liumeng0403/lm.solution.git" 部分get

    這部分是遠端倉庫的地址(URI) ,可根據實際狀況替換爲本身項目的遠端倉庫地址。

  3.語法

    git clone [--template=<template_directory>]

        [-l]

        [-s]

        [--no-hardlinks]

        [-q]

        [-n]

        [--bare]

        [--mirror]

        [-o <name>]

        [-b <name>]

        [-u <upload-pack>]

        [--reference <repository>]

        [--separate-git-dir <git dir>]

        [--depth <depth>]

        [--[no-]single-branch]

        [--recursive|--recurse-submodules]

        [--]

        <repository>

        [<directory>] 

     上面是一個完整的 git clone 語法語句,只有 「<repository>」 項部分是必須項,語法較爲簡單,可自行谷歌查看每項具體含義。

 

 

 

 

                                         蒙

                                    2018-06-09 00:22 週六

相關文章
相關標籤/搜索