D
D
Dmitry2014-09-26 11:16:48
git
Dmitry, 2014-09-26 11:16:48

How to copy changes from one git directory to another?

I've been familiar with the git for a couple of days, but I need to figure it out. The question is the following: there are two directories (branches?) that need to be transferred from one (dev) to production. dev has been cloned from production. Both branches, as I understand it, are master. And git tells me this:

Your branch is ahead of 'origin/master' by 7 commits.

What's the matter? Googling does not provide direct answers, only speculation.
Thank you.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
P
Puma Thailand, 2014-09-26
@another_dream

you did something stupid, you
need to use brunches, and then merge the brunch into the master, it feels like you are trying to work with the git as with svn

V
vman, 2014-09-26
@vman

one.

git checkout dev
git commit -am "commit"
git push
git checkout production
git merge dev

2.
git pull или 
git pull --rebase

I recommend that before making changes, make a copy of the project and read git-scm.com/book/ru/%D0%92%D0%B2%D0%B5%D0%B4%D0%B5...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question