git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Blair Noctis <ncts@debian.org>
To: Simon Richter <sjr@debian.org>
Cc: git@vger.kernel.org, debian-devel@lists.debian.org
Subject: Re: Representing Debian Metadata in Git
Date: Fri, 23 Aug 2024 03:27:31 +0800	[thread overview]
Message-ID: <5b59d9f0-74a2-418c-acd7-ff1ecbfea467@sail.ng> (raw)
In-Reply-To: <eb963843-9e2c-49f2-911f-fa36f33f9bfd@debian.org>

[-- Attachment #1: Type: text/plain, Size: 3605 bytes --]

On 2024-08-20 15:10, Simon Richter wrote:
(...)
> Right now, git is used mainly as a network file system, and only tagged 
> releases are expected to be consistent enough to compile, because often 
> going from one consistent state to another as an atomic operation would 
> require multiple changes to be applied in the same commit.
> 
> The imported archive is represented either directly as a tree (which may 
> be imported from the upstream project if no files are undistributable 
> for Debian), or via a mechanism that can reproduce a compressed archive 
> that is bitwise identical to the upstream release, from a tree and some 
> additional patch data.
> 
> The patch stack is stored as a set of patches inside a directory, and 
> rebased using quilt.
> 
> An alternate representation stores the patch stack as a branch that is 
> rebased using git, and then exported to single files.
> 
> The Debian changelog is stored as a file inside Git, but some automation 
> exists to update this from Git commit messages.
> 
> Debian changelog entries refer to bugs in the Debian Bug Tracking 
> system. There is a desire to also incorporate forges (currently, GitLab) 
> and refer to the forges' issue tracker from commit messages (where the 
> issue tracker is used for team collaboration, while the Debian BTS is 
> used for user-visible bugs).
> 
> All of this is very silly, because we're essentially storing metadata as 
> data because we cannot express in Git what we're actually doing, and the 
> conflicting priorities people have have led to conflicting solutions.
> 
> I'd like to xkcd 927 this now, and find a common mapping.

Here's my very likely very naive 2 cents: we are basically maintaining a 
fork for each non-native package.

Being a fork, a "Debianized" package can also live like other "upstream" 
forks: with its own branch based on the original, make necessary changes
and record them as commits; merge original onto its own branch, dealing
with conflicts; maintain its own changelog; rinse and repeat.

Debian-specific metadata can be represented structurally in commit 
messages, or if necessary, (still) in a plain debian/ subdirectory that
won't conflict with upstream.

Then,

>  From a requirements perspective, I'd like to be able to
> 
>   - express patches as commits:
>     - allow cherry-picking upstream commits as Debian patches
>     - allow cherry-picking Debian patches for upstream submission
>   - generate the Debian changelog from changes committed to Git
>   - express filter steps for generating the upstream archive(s) from a 
> tree‑ish and some metadata
>   - store upstream signatures inside Git
>   - keep a history of patches, including patches applied to previously 
> released packages

these are naturally met; and

(...)
> Changes to packaging would still be represented as commit objects 
> containing a tree, but that tree would contain a special entry for the 
> "debian" subdirectory that points to the last packaging change.

no more needed.

> This is very high-level so far, because I'd like to get some feedback 
> first on whether it makes sense to pursue this further.This would use 
> up the last unused three-bit object type in Git, so it will have to be 
> very generic on this side to not block future development -- and it 
> would require a lot of design effort on the Debian side as well to 
> hammer out the details.

Even less thought out, but probably easier to implement once the design 
is finished. ;)

-- 
Sdrager,
Blair Noctis


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

  parent reply	other threads:[~2024-08-22 19:28 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-20  7:10 Representing Debian Metadata in Git Simon Richter
2024-08-21 21:37 ` Chris Hofstaedtler
2024-08-21 23:11   ` rsbecker
2024-08-21 23:51     ` Chris Hofstaedtler
2024-08-22 19:27 ` Blair Noctis [this message]
2024-08-23  2:20 ` Sean Whitton

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=5b59d9f0-74a2-418c-acd7-ff1ecbfea467@sail.ng \
    --to=ncts@debian.org \
    --cc=debian-devel@lists.debian.org \
    --cc=git@vger.kernel.org \
    --cc=sjr@debian.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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).