lab 36 Review the Cloned Repository
Goals
- Learn about branches on remote repositories.
Look at the cloned repository
Let’s take a look at the cloned repository.
Execute:
cd cloned_hello ls
Output:
$ cd cloned_hello $ ls README lib package.json
You should see a list of all the files in the top level of the original repository (README
, Rakefile
and lib
).
Review the Repository History
Execute:
git hist --all
Output:
$ git hist --all * c6d9ed3 2019-06-27 | Updated package (HEAD -> main, origin/main, origin/greet, origin/HEAD) [Halle Bot] * 56af19d 2019-06-27 | Hello uses Greeter [Halle Bot] * 1e7679d 2019-06-27 | Added greeter class [Halle Bot] * 3aa3064 2019-06-27 | Added README [Halle Bot] * 2b04803 2019-06-27 | Added a package.json. [Halle Bot] * b65b430 2019-06-27 | Moved hello.js to lib [Halle Bot] * 4535421 2019-06-27 | Add an author/email comment [Halle Bot] * 59992ce 2019-06-27 | Added a comment (tag: v1) [Halle Bot] * 20a6c79 2019-06-27 | Added a default value (tag: v1-beta) [Halle Bot] * 6915d41 2019-06-27 | Using process.argv [Halle Bot] * 284070d 2019-06-27 | First Commit [Halle Bot]
You should now see a list of the all the commits in the new repository, and it should (more or less) match the history of commits in the original repository. The only difference should be in the names of the branches.
Remote branches
You should see a main branch (along with HEAD) in the history list. But you will also have number of strangely named branches (origin/main, origin/greet and origin/HEAD). We’ll talk about them in a bit.