ALT Linux Team development discussions
 help / color / mirror / Atom feed
From: Sergey Afonin <asy@altlinux.ru>
To: ALT Linux Team development discussions <devel@lists.altlinux.org>
Subject: Re: [devel] Git: как правильно избавиться от патча в виде бранча ?
Date: Tue, 13 Oct 2015 17:47:25 +0400
Message-ID: <201510131747.25434.asy@altlinux.ru> (raw)
In-Reply-To: <560129A0.2000508@solin.spb.ru>

On Tuesday 22 September 2015, Aleksey Avdeev wrote:

> а) Отобразить фактические изменения происходящие при мерже бранча
>    с патчем: 
> 
> $ git diff <merge_commit>{^,}
> 
> б) Отображаем коммиты, в которых происходят похожие изменения:
> 
> $ git log -S '<подстрока>' <бранч> -- <файл>

Так оказалось проще. На всякий случай, напишу запишу тут
последовательность после нахождения коммита, вдруг пригодится.

1. Нашёлся коммит 627ccbb6e09bbcbabace38ec6d3a0b8dbd613186

2. Задействованная последовательность мерджей (избавляемся от autocreate):
patches/alt/004-configs -> patches/other/005-autocreate
patches/other/005-autocreate -> patches/debian/007-fix_docs

$ git checkout patches/debian/007-fix_docs
$ git revert 627ccbb6e09bbcbabace38ec6d3a0b8dbd613186
error: could not revert 627ccbb... Apply autocreate and autosieve patches for Cyrus IMAP Server 2.4.4
hint: after resolving the conflicts, mark the corrected paths
hint: with 'git add <paths>' or 'git rm <paths>'
hint: and commit the result with 'git commit'

Тут случилась засада с конфликтом. На всякий случай, сверился с
аналогичным файлом (найден по наличию <<<<) из patches/alt/004-configs.
Фактически, можно было файл скопировать. Но это при условии,
что в patches/alt/004-configs ещё не смерджено ничего нового
после предыдущего раза, или известно, что этот файл не затронут.

$ git commit -a

В общем-то, всё, при очередном обновлении можно мерджить
patches/alt/004-configs -> patches/debian/007-fix_docs

Ну и, чтобы не мешался:
$ git branch -d patches/other/005-autocreate

-- 
С уважением, Сергей Афонин.


  reply	other threads:[~2015-10-13 13:47 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-08  6:58 Sergey Afonin
2015-09-08 12:15   ` Sergey Afonin
2015-09-11 11:50 ` Aleksey Avdeev
2015-09-22  7:08   ` Sergey Afonin
2015-09-22 10:12     ` Aleksey Avdeev
2015-10-13 13:47       ` Sergey Afonin [this message]
2015-09-22 10:39     ` Michael Shigorin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201510131747.25434.asy@altlinux.ru \
    --to=asy@altlinux.ru \
    --cc=devel@lists.altlinux.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

ALT Linux Team development discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/devel/0 devel/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 devel devel/ http://lore.altlinux.org/devel \
		devel@altlinux.org devel@altlinux.ru devel@lists.altlinux.org devel@lists.altlinux.ru devel@linux.iplabs.ru mandrake-russian@linuxteam.iplabs.ru sisyphus@linuxteam.iplabs.ru
	public-inbox-index devel

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.devel


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git