Stefano Zacchiroli | 15 Jul 20:27
Favicon

how to generate patches out of $DVCS branches: best practices?

I'm a happy (Debian) package maintainer which have just switched most of
his packages from svn to git. All nice, finally I can work directly on a
real source code tree instead of fiddling with patch management system.
Nevertheless, patches are separate in topic branches which enable
knowing the conceptual changes applied to upstream sources.

But.

Even though I can declare where my git repository for package management
is, there is still people only playing with the (Debian) source package.
Unfortunately, there all changes are flattened in .diff.gz, with neither
change separation, nor description of which changes have been made.

I know I can use git format-patch to serialize patches into patch series
and make them available with dpatch/quilt/..., and precisely here is my
question. Have I to do that by hand and by myself? Even though I can do
it, I'm convinced there is room for creating a best practice on this, if
not even some tools. Is anybody aware of anything like that?

Specifically for Debian: do we have any guideline on how to do that? If
not it is probably worth to create one ...

And finally, the problem of the problems: how about the situation where
one patch for topic branch is not enough as topic branches have got
intertwined? (I guess this can happen fairly easily with changes
evolution, unless git rebase is used). A guideline/best practice on that
as well would be utterly welcome.

TIA,
Cheers.
(Continue reading)

John Goerzen | 15 Jul 20:38

Re: how to generate patches out of $DVCS branches: best practices?

Stefano Zacchiroli wrote:
> Specifically for Debian: do we have any guideline on how to do that? If
> not it is probably worth to create one ...
> 
> And finally, the problem of the problems: how about the situation where
> one patch for topic branch is not enough as topic branches have got
> intertwined? (I guess this can happen fairly easily with changes
> evolution, unless git rebase is used). A guideline/best practice on that
> as well would be utterly welcome.

I don't split out patches, but all my Debian packages live on
git.debian.org (except software where I'm the upstream, in which case
it's on my own git server).  Using gitweb, people can inspect the
changelog and download diffs of individual changesets.  You can also
craft URLs for people that will do things such as spit out a diff
between upstream and debian heads, or between two different Debian releases.

-- John
Guido Günther | 21 Jul 04:54

Re: how to generate patches out of $DVCS branches: best practices?

On Tue, Jul 15, 2008 at 08:31:04PM +0200, Stefano Zacchiroli wrote:
> Specifically for Debian: do we have any guideline on how to do that? If
> not it is probably worth to create one ...
For simple patches I maintain a patch-queue branch (which gets rebased
of course) and debian/rules has:

redo-patches::
	rm -f debian/patches/*
	git format-patch -N -o debian/patches master...patch-queue | \
		sed -e 's%debian/patches/%%' > debian/patches/series

Batches on this branch usually come from topic brnaches. This keeps
dpatch like patch information in the header. I usually squash topic
branches into a single commit for that with git merge --squash.
 -- Guido

martin f krafft | 23 Sep 08:25
Favicon

Re: how to generate patches out of $DVCS branches: best practices?

also sprach Stefano Zacchiroli <zack@...> [2008.07.15.2031 +0200]:
> I'm a happy (Debian) package maintainer which have just switched
> most of his packages from svn to git. All nice, finally I can work
> directly on a real source code tree instead of fiddling with patch
> management system. Nevertheless, patches are separate in topic
> branches which enable knowing the conceptual changes applied to
> upstream sources.

So that I can remove this thread from my pending list, have you
looked at topgit? I know it's still rough, but I think it's what
you're looking for. topgit's source package has a README.source, and
I'd love comments, especially how to improve the process:

  http://git.debian.org/?p=collab-maint/topgit.git;a=blob;f=debian/README.source;hb=HEAD

--

-- 
 .''`.   martin f. krafft <madduck@...>
: :'  :  proud Debian developer, author, administrator, and user
`. `'`   http://people.debian.org/~madduck - http://debiansystem.info
  `-  Debian - when you have better things to do than fixing systems

"in a country where the sole employer is the state, opposition means
 death by slow starvation. the old principle: who does not work shall
 not eat, has been replaced by a new one: who does not obey shall not
 eat."
                                                 -- leon trotsky, 1937
_______________________________________________
vcs-pkg-discuss mailing list
(Continue reading)

Stefano Zacchiroli | 24 Sep 11:26
Favicon

Re: how to generate patches out of $DVCS branches: best practices?

On Tue, Sep 23, 2008 at 08:25:38AM +0200, martin f krafft wrote:
> also sprach Stefano Zacchiroli <zack@...> [2008.07.15.2031 +0200]:
> > I'm a happy (Debian) package maintainer which have just switched
> > most of his packages from svn to git. All nice, finally I can work
> > directly on a real source code tree instead of fiddling with patch
> > management system. Nevertheless, patches are separate in topic
> > branches which enable knowing the conceptual changes applied to
> > upstream sources.
> 
> So that I can remove this thread from my pending list, have you
> looked at topgit? I know it's still rough, but I think it's what
> you're looking for. topgit's source package has a README.source, and

I've looked at least at what topgit is and I indeed got convinced that
it is what I was looking for. Still, I haven't put it into use to be
able to comment any further.

Cheers.

--

-- 
Stefano Zacchiroli -*- PhD in Computer Science \ PostDoc @ Univ. Paris 7
zack@{upsilon.cc,pps.jussieu.fr,debian.org} -<>- http://upsilon.cc/zack/
I'm still an SGML person,this newfangled /\ All one has to do is hit the
XML stuff is so ... simplistic  -- Manoj \/ right keys at the right time
_______________________________________________
vcs-pkg-discuss mailing list
vcs-pkg-discuss@...
http://lists.alioth.debian.org/mailman/listinfo/vcs-pkg-discuss
(Continue reading)


Gmane