Shallow clone cannot fetch new commits/branches?

后端 未结 4 2028
南笙
南笙 2021-01-29 07:36

I have this:

git clone --depth=1  app
cd app
git fetch origin
git checkout a119b1076dd45a88a3609c4f7893ef3d82f9a4ee

but it says:

4条回答
  •  温柔的废话
    2021-01-29 08:10

    When you're doing a shallow clone you may want to specify a branch you are going to fetch:

    git clone --depth=1 --branch=me/work  app
    

提交回复
热议问题