Questions tagged [git-pull]

Fetches changes from a remote repository and incorporates them into the current branch of a Git repository.

git pull is used whenever changes from a remote repository need to be fetched and incorporated into the local repository. Internally git pull first performs a git fetch to get the remote branches updated and then a git merge to incorporate the changes into the current branch.

1231 questions
14
votes
2 answers

Resolve merge conflict only for some files and commit to branch for other teams to resolve theirs

In short, we have one repo which hosts code for different functional teams, i.e. server-side, mobile, ci, automation qa etc. Now when we are trying to pull down from support-branch bug fixes into dev-release-branch a lot of conflicts appear related…
monitor
  • 251
  • 2
  • 9
14
votes
3 answers

Default behaviour of 'git pull'

Why is that git pull pulls everything including newly created remote branches but git pull origin master does not? I'm using git version 2.9.3.windows.2.
Thaadikkaaran
  • 5,088
  • 7
  • 37
  • 59
14
votes
2 answers

What does Fast-forward mean when pulling from remote?

I run git pull twice and get the following out: $ git pull remote: Counting objects: 1, done. remote: Total 1 (delta 0), reused 0 (delta 0) Unpacking objects: 100% (1/1), done. From git.assembla.com:my-project da3f54c..bb335a4 master ->…
abg
  • 2,002
  • 7
  • 39
  • 63
14
votes
2 answers

Git pull aborts itself, local file changes will be overwritten by merge

I have changed a file that my friend is working at the same time. I did some changes and now I want to push it but it says I should pull first. When I git pull, it says: error: Your local changes to the following files would be overwritten by…
Sasha_8
  • 143
  • 1
  • 1
  • 8
14
votes
1 answer

Pulling just one directory out of a git repo

I have a git repo that I want to do a pull from. I do a normal git pull with no problems. The issue is that I want just one certain directory out of the repo. My thinking was that I could use a .gitignore file with a rule like this: #Ignore all…
Dan
  • 1,222
  • 2
  • 17
  • 33
14
votes
3 answers

Is it possible to 'git pull' only the next commit?

I understand git pull will update the working branch to the tip of a remote branch that it tracks. So let's say if I do git pull, it will pull in all the latest changes. In my case, it will pull in 5 changes on top of my tree. Is there a way to…
Adam S
  • 8,945
  • 17
  • 67
  • 103
13
votes
1 answer

What's the status of my git submodule, and how can I clean it up?

Being a relative submodules noob, I wanted to update my submodule with from its origin, and did: git pull This resulted in: remote: Counting objects: 111, done. remote: Compressing objects: 100% (3/3), done. remote: Total 57 (delta 54), reused 57…
eoinoc
  • 3,155
  • 3
  • 24
  • 39
13
votes
1 answer

How to do git merge/pull correctly: You have not concluded your merge (MERGE_HEAD exists)

I am a newbie to Git and having trouble understanding how to use Git. I have been using CVS so going through some learning curve for Git. Here is what all I tried Now I had changed only two files PromoServiceImpl.java and build.sql. However having…
Smiles in a Jar
  • 479
  • 1
  • 6
  • 20
13
votes
3 answers

What does "would be overwritten by merge" mean?

When pulling from a team based Git remote repository, I get this message: "C:\Program Files (x86)\Git\bin\git.exe" pull --progress "origin" +refs/heads/master:refs/remotes/origin/master Updating 71089d7..4c66e71 error: Your local changes to the…
datps
  • 768
  • 1
  • 6
  • 16
13
votes
4 answers

Unable to push to git Repository. It hangs after "Writing Objects: 100%"

I am running git daemon with the following command. c:\cygwin\bin\git daemon --reuseaddr --base-path=/cygdrive/S --export-all --verbose --enable=receive-pack I am able to clone and pull updates but when I try to push I get $ git push origin…
JasonRed
  • 133
  • 1
  • 5
13
votes
3 answers

git pull: keeps telling me to stash local changes before pulling

When I am trying to pull my git repository with "git pull", it keeps telling me that I have local changes although I have not touched any of the mentioned files. Can someone explain this behavior and knows a solution? git status: # On branch…
Jasper
  • 343
  • 1
  • 2
  • 9
13
votes
3 answers

Git: Every pull on origin master causes a merge with message

Every time I do a git pull origin master Git pops up an editor and asks me to write a comment about the merge before committing. Any idea why this might happen? Another developer is also doing work on master and has not had this issue. As far as…
Studio4Development
  • 725
  • 1
  • 6
  • 18
13
votes
2 answers

CONFLICT (content): Merge conflict in

I have a server with a remote and whenever I git pull I get those stupid ====== and HEAD >>>> things in my files causing my server to not work properly. How can I prevent this every time I want to update my server to be the same as my…
Tony
  • 2,382
  • 7
  • 32
  • 51
12
votes
3 answers

How to let git pull from branch not from tag?

Our repo happens to have a tag that has the same name as the branch name. So when I try to pull from that branch, git confused and pulled from tag, like this. I have to delete that tag first to make my git pull work. So how do I tell git pull from…
Qiulang
  • 10,295
  • 11
  • 80
  • 129
12
votes
1 answer

Rebasing after a Pull request

I have a feature branch test. I made my changes and committed my changes to that branch. Meanwhile my master tip was changed (Assume it had more commits from other developers). Before pushing my changes to my remote branch, I did a git rebase and…
Venu
  • 1,513
  • 3
  • 19
  • 37