Rodrigo Souza
Rodrigo Souza

Reputation: 7332

Resolving conflicts in git version control

I've got a big problem but I bet it's easy to solve. I'm developing a website together with a friend using GiT for versioning control. We've just modified different parts of the same CSS file and then commited, then he pushed his commit. We're both using master branches in local and remote repository for we don't know how to deal with it very well. He pushed his commit to the remote repository, I don't.

What happens is. In the remote repository we have a file with A, I have a file with B and I want it to have A and B together in the remote and our local repository

What should I do? I'm also accepting some suggestions about how we can keep on developing the website in a way we don't have too much problems to deal with it (maybe creating branches, some techniques or patterns we should follow, or anything else 'cause i'm new at versioning control)

Upvotes: 1

Views: 541

Answers (1)

Mewp
Mewp

Reputation: 4715

First, use git pull to download his changes into your local repository, then resolve any conflicts that git will inform you about.

when you're done with it, commit and push the changes.

Upvotes: 1

Related Questions