M
M
Michael2018-09-05 15:56:34
git
Michael, 2018-09-05 15:56:34

Why does git lose branch affinity after push?

One project - two users. When pushing the first one, there is no problem. The second goes to the same branch and continues to work. After pushing the second one, the first one gets the following:

> git pull
У текущей ветки нет информации об отслеживании.
Пожалуйста, укажите с какой веткой вы хотите слить изменения.
Для дополнительной информации, смотрите git-pull(1).

    git pull <внешний-репозиторий> <ветка>

Если вы хотите указать информацию о отслеживаемой ветке, выполните:

    git branch --set-upstream-to=<внешний-репозиторий>/<ветка> branch-name

In short, when pushing from another account, the first one cannot do a git pull and is forced to relink the branches. Why is the connection lost?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question