[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Understanding Git workflow around DEP-14



On Mon, Mar 11, 2019 at 01:50:49PM -0500, Matt Zagrabelny wrote:
> On Mon, Mar 11, 2019 at 1:30 PM <deb251@lewenberg.com> wrote:
> 
> > I am packaging some upstream software for Debian and I am trying to
> > understand the workflow around "DEP-14: Recommended layout for Git
> > packaging repositories".
> >
> > Looking at DEP-14 I might have these Git branches:

The DEP-14 we are talking about is https://dep-team.pages.debian.net/deps/dep14/

> >    master
> >    debian/master
> >    debian/stretch
> >    upstream/latest
> >
> > I understand that the Debian packaging files in debian/ will appear in
> > the "debian/*" branch, but my general question is: what is the workflow
> > around all these branches? When and how do files get merged from one
> > branch to another?
> >
> 
> git checkout debian/master
> git merge upstream/latest
> 
> You want to keep the upstream/latest branch free of Debian specific
> packaging bits.
> 
> You can use tags to mark any upstream releases. Here is an example:
> 
> $ git tag
> debian/2.4-1
> debian/2.4-2
> upstream/2.4
> 
> More specifically:
> >
> > 1. Besides the debian/ directory, what is the difference between the
> > "debian/master" branch and the "upstream/latest" branch?
> >
> 
> I don't believe anything.

True.
It is the idea about branches.


> > 2. What should the "master" branch be used for?

Consider the string "master" a label for _your leading branch_


> I don't use the master branch with DEP-14. I believe the DEP is stating
> that you'd use "master" for native packages - which from the sounds of it,
> yours is not. Therefore, I'd not use "master".

But you have your own leading branch 


> > 3. When a new upstream tarball is released, where should it be imported?
> >
> 
> Assuming you have a remote named "github", I suppose you'd do something
> like:
> 
> git pull github upstream/latest


I think it should be     (be warned  _not tested_ )   avoid that your current branch gets pollueted.

} git checkout upstream/latest
} git pull github
 

> Then, you'd do:
> 
> git checkout debian/master
> git merge upstream/latest


Groeten
Geert Stappers
-- 
DEP14 for the win


Reply to: