When I run it on my git repo this is what I get.
git pull .
From .
* branch HEAD -> FETCH_HEAD
Current branch rel_20121207 is up to date.
But when I run just git pull
it actually updates from the remote.
I would like to know what exactly happened when I ran git pull .
Git pull is a command that allows you to fetch from and integrate with another repository or local branch. From this definition, you can see that a Git pull is actually a Git fetch followed by an additional action(s)—typically a Git merge.
git pull isn't bad if used properly. If you are the only owner and user of the git repository, it is okay to use it. The pull command is actually a combination of two commands, git fetch and git merge . This is okay if your local branch is in sync with the remote branch.
The term pull is used to receive data from GitHub. It fetches and merges changes from the remote server to your working directory. The git pull command is used to pull a repository.
Git Fetch is the command that tells the local repository that there are changes available in the remote repository without bringing the changes into the local repository. Git Pull on the other hand brings the copy of the remote directory changes into the local repository.
Ha, this one's fun. git pull
takes a remote name, or a file spec. You're giving it a file spec ('.
' means the current directory), so it's treating your current repo like a remote, and throwing your current HEAD into FETCH_HEAD. You're pulling your repo into itself; essentially it's doing nothing.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With