stgit icon indicating copy to clipboard operation
stgit copied to clipboard

ignore patches which already landed in upstream/mainline

Open cz172638 opened this issue 7 years ago • 3 comments

while playing with patch queue for kernel, i realized, that some patches already landed in mainline kernel. using 'patch -R -p1 -i patches/some.patch' i verified, that patch was completely accepted, so i commented it out. it would be nice to have option for import command to check using revert if patch is alreay in current code base

cz172638 avatar Dec 08 '17 15:12 cz172638

stg push and import have a --merged option but I haven't thought of doing it for import. You could import it on a base you know it would apply and rebase it afterwards on top of mainline.

ctmarinas avatar Jan 20 '18 19:01 ctmarinas

i use stgit for preparation of preempt_rt patch when applying standalone preempt_rt patch for older version fails.

preempt_rt patch is in fact queue of small patches. part of that queue are few bugfixes of kernel itself, when patch lands in mainline.

to use stgit for automated builds i need two things:

  • ignore patches which were already merged

  • if hunk will fail with std. context of 3 lines use 1 line context (now yet figured out how pass libgit2's context_lines from flags to stgit)

cz172638 avatar Jan 30 '18 21:01 cz172638

importing it on known base will work only with sources with history, but my workflow is with archive in which is called git init so history is very different.

cz172638 avatar Oct 21 '18 07:10 cz172638