Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I pull changes from github repository to my local machine?

Tags:

github

I've seen several questions/answers very similar to this but still not sure I understand if they are what I need. So accept my apologies if this was covered before by something similar.

I have a private GitHub account with several repositories. I created these from my mac, pushed them to GitHub and everything works great.

From my Ubuntu desktop, I did a git clone and pulled a couple of the repositories to that desk top. Now from Ubuntu, I make a change to a file, add it, commit it, and push it to GitHub.

Question: How (what command) on my mac do I use to pull that change down to my local repository so I get that change(s)? UserName is JohnCowan, repo is sacnomadgolf.git

Thanks for the help.

like image 312
John Cowan Avatar asked Mar 28 '13 20:03

John Cowan


People also ask

How do I pull a remote repository to local?

The content of the multiple remote repositories can be pulled to the local drive by using the command, `git pull origin` or `git pull upstream`.

How do I pull changes from a cloned repository?

To pull down (i.e. copy) the changes merged into your fork, you can use the Terminal and the git pull command. To begin: On your local computer, navigate to your forked repo directory. Once you have changed directories to the forked repo directory, run the command git pull .


1 Answers

You said you made the repo on your Mac. Then you can just do git pull in the folder you have the repository in.

A really good resource on Git, with explanatory illustrations about the "Git workflow":

http://git-scm.com/doc

like image 172
Sami N Avatar answered Sep 28 '22 12:09

Sami N