Faithfully clone a github repository












1














I am trying to clone the Caffe SSD implementation: https://github.com/weiliu89/caffe/tree/ssd



So I run:



$ git clone https://github.com/weiliu89/caffe.git
$ ls caffe


and get the expected output, a list of the top level files, as seen on the github web interface.



but if I explore deeper, e.g.:



$ ls caffe/docker/
cpu gpu README.md


I get different files/folders to those appearing on the web interface (https://github.com/weiliu89/caffe/tree/ssd/docker).



How can I fix this?










share|improve this question




















  • 3




    That is what I see in the web interface: github.com/weiliu89/caffe/tree/master/docker. Are you sure you're comparing the correct branches?
    – jonrsharpe
    Nov 23 '18 at 15:50


















1














I am trying to clone the Caffe SSD implementation: https://github.com/weiliu89/caffe/tree/ssd



So I run:



$ git clone https://github.com/weiliu89/caffe.git
$ ls caffe


and get the expected output, a list of the top level files, as seen on the github web interface.



but if I explore deeper, e.g.:



$ ls caffe/docker/
cpu gpu README.md


I get different files/folders to those appearing on the web interface (https://github.com/weiliu89/caffe/tree/ssd/docker).



How can I fix this?










share|improve this question




















  • 3




    That is what I see in the web interface: github.com/weiliu89/caffe/tree/master/docker. Are you sure you're comparing the correct branches?
    – jonrsharpe
    Nov 23 '18 at 15:50
















1












1








1







I am trying to clone the Caffe SSD implementation: https://github.com/weiliu89/caffe/tree/ssd



So I run:



$ git clone https://github.com/weiliu89/caffe.git
$ ls caffe


and get the expected output, a list of the top level files, as seen on the github web interface.



but if I explore deeper, e.g.:



$ ls caffe/docker/
cpu gpu README.md


I get different files/folders to those appearing on the web interface (https://github.com/weiliu89/caffe/tree/ssd/docker).



How can I fix this?










share|improve this question















I am trying to clone the Caffe SSD implementation: https://github.com/weiliu89/caffe/tree/ssd



So I run:



$ git clone https://github.com/weiliu89/caffe.git
$ ls caffe


and get the expected output, a list of the top level files, as seen on the github web interface.



but if I explore deeper, e.g.:



$ ls caffe/docker/
cpu gpu README.md


I get different files/folders to those appearing on the web interface (https://github.com/weiliu89/caffe/tree/ssd/docker).



How can I fix this?







git git-clone






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 23 '18 at 16:01

























asked Nov 23 '18 at 15:47









Loop

84




84








  • 3




    That is what I see in the web interface: github.com/weiliu89/caffe/tree/master/docker. Are you sure you're comparing the correct branches?
    – jonrsharpe
    Nov 23 '18 at 15:50
















  • 3




    That is what I see in the web interface: github.com/weiliu89/caffe/tree/master/docker. Are you sure you're comparing the correct branches?
    – jonrsharpe
    Nov 23 '18 at 15:50










3




3




That is what I see in the web interface: github.com/weiliu89/caffe/tree/master/docker. Are you sure you're comparing the correct branches?
– jonrsharpe
Nov 23 '18 at 15:50






That is what I see in the web interface: github.com/weiliu89/caffe/tree/master/docker. Are you sure you're comparing the correct branches?
– jonrsharpe
Nov 23 '18 at 15:50














2 Answers
2






active

oldest

votes


















0














Clone the branch ssd instead of master:



git clone -b ssd https://github.com/weiliu89/caffe.git





share|improve this answer

















  • 1




    Or you can try git clone --branch=ssd https://github.com/weiliu89/caffe.git.
    – double-beep
    Nov 24 '18 at 12:25










  • It's absolutely the same. -b is just a short alias for --branch.
    – phd
    Nov 24 '18 at 12:26












  • I know it. Just to make it better.
    – double-beep
    Nov 24 '18 at 12:37



















0














You problem is that when you do a git clone by default you are in the master branch.
You want to switch to ssd branch. To do it:



git checkout ssd


And then you will see files of this branch. You can check wich branch are you using wit the following command:



git branch





share|improve this answer























  • with git checkout -b you will create a new branch. Maybe without the -b option?
    – double-beep
    Nov 23 '18 at 16:03










  • yes, you are right. I have modified my answer. With -b you create a new branch.
    – Pau Campaña Soler
    Nov 23 '18 at 16:21











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53449581%2ffaithfully-clone-a-github-repository%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























2 Answers
2






active

oldest

votes








2 Answers
2






active

oldest

votes









active

oldest

votes






active

oldest

votes









0














Clone the branch ssd instead of master:



git clone -b ssd https://github.com/weiliu89/caffe.git





share|improve this answer

















  • 1




    Or you can try git clone --branch=ssd https://github.com/weiliu89/caffe.git.
    – double-beep
    Nov 24 '18 at 12:25










  • It's absolutely the same. -b is just a short alias for --branch.
    – phd
    Nov 24 '18 at 12:26












  • I know it. Just to make it better.
    – double-beep
    Nov 24 '18 at 12:37
















0














Clone the branch ssd instead of master:



git clone -b ssd https://github.com/weiliu89/caffe.git





share|improve this answer

















  • 1




    Or you can try git clone --branch=ssd https://github.com/weiliu89/caffe.git.
    – double-beep
    Nov 24 '18 at 12:25










  • It's absolutely the same. -b is just a short alias for --branch.
    – phd
    Nov 24 '18 at 12:26












  • I know it. Just to make it better.
    – double-beep
    Nov 24 '18 at 12:37














0












0








0






Clone the branch ssd instead of master:



git clone -b ssd https://github.com/weiliu89/caffe.git





share|improve this answer












Clone the branch ssd instead of master:



git clone -b ssd https://github.com/weiliu89/caffe.git






share|improve this answer












share|improve this answer



share|improve this answer










answered Nov 23 '18 at 17:31









phd

20.9k52442




20.9k52442








  • 1




    Or you can try git clone --branch=ssd https://github.com/weiliu89/caffe.git.
    – double-beep
    Nov 24 '18 at 12:25










  • It's absolutely the same. -b is just a short alias for --branch.
    – phd
    Nov 24 '18 at 12:26












  • I know it. Just to make it better.
    – double-beep
    Nov 24 '18 at 12:37














  • 1




    Or you can try git clone --branch=ssd https://github.com/weiliu89/caffe.git.
    – double-beep
    Nov 24 '18 at 12:25










  • It's absolutely the same. -b is just a short alias for --branch.
    – phd
    Nov 24 '18 at 12:26












  • I know it. Just to make it better.
    – double-beep
    Nov 24 '18 at 12:37








1




1




Or you can try git clone --branch=ssd https://github.com/weiliu89/caffe.git.
– double-beep
Nov 24 '18 at 12:25




Or you can try git clone --branch=ssd https://github.com/weiliu89/caffe.git.
– double-beep
Nov 24 '18 at 12:25












It's absolutely the same. -b is just a short alias for --branch.
– phd
Nov 24 '18 at 12:26






It's absolutely the same. -b is just a short alias for --branch.
– phd
Nov 24 '18 at 12:26














I know it. Just to make it better.
– double-beep
Nov 24 '18 at 12:37




I know it. Just to make it better.
– double-beep
Nov 24 '18 at 12:37













0














You problem is that when you do a git clone by default you are in the master branch.
You want to switch to ssd branch. To do it:



git checkout ssd


And then you will see files of this branch. You can check wich branch are you using wit the following command:



git branch





share|improve this answer























  • with git checkout -b you will create a new branch. Maybe without the -b option?
    – double-beep
    Nov 23 '18 at 16:03










  • yes, you are right. I have modified my answer. With -b you create a new branch.
    – Pau Campaña Soler
    Nov 23 '18 at 16:21
















0














You problem is that when you do a git clone by default you are in the master branch.
You want to switch to ssd branch. To do it:



git checkout ssd


And then you will see files of this branch. You can check wich branch are you using wit the following command:



git branch





share|improve this answer























  • with git checkout -b you will create a new branch. Maybe without the -b option?
    – double-beep
    Nov 23 '18 at 16:03










  • yes, you are right. I have modified my answer. With -b you create a new branch.
    – Pau Campaña Soler
    Nov 23 '18 at 16:21














0












0








0






You problem is that when you do a git clone by default you are in the master branch.
You want to switch to ssd branch. To do it:



git checkout ssd


And then you will see files of this branch. You can check wich branch are you using wit the following command:



git branch





share|improve this answer














You problem is that when you do a git clone by default you are in the master branch.
You want to switch to ssd branch. To do it:



git checkout ssd


And then you will see files of this branch. You can check wich branch are you using wit the following command:



git branch






share|improve this answer














share|improve this answer



share|improve this answer








edited Nov 23 '18 at 16:20

























answered Nov 23 '18 at 15:56









Pau Campaña Soler

1636




1636












  • with git checkout -b you will create a new branch. Maybe without the -b option?
    – double-beep
    Nov 23 '18 at 16:03










  • yes, you are right. I have modified my answer. With -b you create a new branch.
    – Pau Campaña Soler
    Nov 23 '18 at 16:21


















  • with git checkout -b you will create a new branch. Maybe without the -b option?
    – double-beep
    Nov 23 '18 at 16:03










  • yes, you are right. I have modified my answer. With -b you create a new branch.
    – Pau Campaña Soler
    Nov 23 '18 at 16:21
















with git checkout -b you will create a new branch. Maybe without the -b option?
– double-beep
Nov 23 '18 at 16:03




with git checkout -b you will create a new branch. Maybe without the -b option?
– double-beep
Nov 23 '18 at 16:03












yes, you are right. I have modified my answer. With -b you create a new branch.
– Pau Campaña Soler
Nov 23 '18 at 16:21




yes, you are right. I have modified my answer. With -b you create a new branch.
– Pau Campaña Soler
Nov 23 '18 at 16:21


















draft saved

draft discarded




















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53449581%2ffaithfully-clone-a-github-repository%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Contact image not getting when fetch all contact list from iPhone by CNContact

count number of partitions of a set with n elements into k subsets

A CLEAN and SIMPLE way to add appendices to Table of Contents and bookmarks